Skip to content

SIGABRT: AsyncStream<String>(context: Found a null pointer in a value of type 'Swift.AsyncStream<Swift.String>._Context' #80002

Open
@barnard-b

Description

@barnard-b

Description

No warnings during build, crashes at runtime.

Reproduction

@main
struct App {
    static func main() async throws {
        let stream = AsyncStream<String> { continuation in
            print(stream)
        }
    }
}

Stack dump

AsyncStream<String>(context: Found a null pointer in a value of type 'Swift.AsyncStream<Swift.String>._Context' (0x2043f4160). Non-Optional values are not allowed to hold null pointers. (Detected while casting to 'Swift.CustomDebugStringConvertible' (0x2043f47a8))
Found a null pointer in a value of type 'Swift.AsyncStream<Swift.String>._Context' (0x2043f4160). Non-Optional values are not allowed to hold null pointers. (Detected while casting to 'Swift.CustomReflectable' (0x2043f4898))

Expected behavior

Does not compile if not valid.

Environment

swift-driver version: 1.115.1 Apple Swift version 6.0.3 (swiftlang-6.0.3.1.10 clang-1600.0.30.1)
Target: arm64-apple-macosx15.0

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.crashBug: A crash, i.e., an abnormal termination of softwaretriage neededThis issue needs more specific labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions