Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-5776] Cannot use Foundation.Data on Ubuntu 16.04 (compiler crash) #48346

Closed
Bouke opened this issue Aug 27, 2017 · 2 comments
Closed

[SR-5776] Cannot use Foundation.Data on Ubuntu 16.04 (compiler crash) #48346

Bouke opened this issue Aug 27, 2017 · 2 comments
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. compiler The Swift compiler in itself regression swift 4.0

Comments

@Bouke
Copy link
Contributor

Bouke commented Aug 27, 2017

Previous ID SR-5776
Radar rdar://problem/34110674
Original Reporter @Bouke
Type Bug
Status Closed
Resolution Cannot Reproduce
Environment

Ubuntu 16.04

swift-4.0-DEVELOPMENT-SNAPSHOT-2017-08-21-a-ubuntu16.04

Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Bug, 4.0Regression
Assignee None
Priority Medium

md5: aa7f1d61eb45a2060460205f8ef5eca5

Issue Description:

bouke@ubuntu:~$ cat foundation_data.swift
import Foundation
Data()

bouke@ubuntu:~$ swift foundation_data.swift
foundation_data.swift:2:1: warning: result of 'Data' initializer is unused
Data()
^ ~~
<unknown>:0: error: fatal error encountered during compilation; please file a bug report with your project and the crash log
<unknown>:0: note: Program used external function '_T010Foundation4DataVACycfC' which could not be resolved!
0 swift 0x0000000003ad79c8
1 swift 0x0000000003ad8106
2 libpthread.so.0 0x00007f86332fd390
3 libc.so.6 0x00007f8631a3c428 gsignal + 56
4 libc.so.6 0x00007f8631a3e02a abort + 362
5 swift 0x00000000004aeef5
6 swift 0x0000000003a74378
7 swift 0x0000000000f3ac6e
8 swift 0x0000000000f399e1
9 swift 0x0000000000f271e9
10 swift 0x00000000004bf2e8
11 swift 0x00000000004ae461
12 swift 0x00000000004aa411
13 swift 0x0000000000465424
14 libc.so.6 0x00007f8631a27830 __libc_start_main + 240
15 swift 0x0000000000462ce9
Stack dump:
0. Program arguments: /home/bouke/swift-4.0-DEVELOPMENT-SNAPSHOT-2017-08-21-a-ubuntu16.04/usr/bin/swift -frontend -interpret foundation_data.swift -disable-objc-interop -color-diagnostics -module-name foundation_data
Aborted (core dumped)
@belkadan
Copy link
Contributor

Bouke, mind checking if compiling with swiftc works, instead of directly running the code with swift?

@swift-ci create

@Bouke
Copy link
Contributor Author

Bouke commented Aug 30, 2017

Not sure why it failed initially, but I cannot reproduce. Both `swift` and `swiftc` compile the code listed just fine.

bouke@ubuntu:~$ swiftenv which swift
/home/bouke/.swiftenv/versions/4.0-DEVELOPMENT-SNAPSHOT-2017-08-21-a/usr/bin/swift
bouke@ubuntu:~$ cat foundation_data.swift
import Foundation
print(Data())

bouke@ubuntu:~$ swift foundation_data.swift
0 bytes
bouke@ubuntu:~$ swiftc foundation_data.swift
bouke@ubuntu:~$

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. compiler The Swift compiler in itself regression swift 4.0
Projects
None yet
Development

No branches or pull requests

3 participants