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

error: copy of noncopyable typed value #78082

Open
jamieQ opened this issue Dec 10, 2024 · 0 comments
Open

error: copy of noncopyable typed value #78082

jamieQ opened this issue Dec 10, 2024 · 0 comments
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. triage needed This issue needs more specific labels

Comments

@jamieQ
Copy link
Contributor

jamieQ commented Dec 10, 2024

Description

reporting copy of a non-copyable type as instructed by the compiler error

Reproduction

struct NC: ~Copyable {}
func f(_ nc: consuming NC) -> () -> Void {
    { nc }
    `- error: copy of noncopyable typed value. This is a compiler bug. Please file a bug with a small example of the bug
}

Expected behavior

better diagnostics explaining the error

Environment

Swift version 6.2-dev (LLVM 4930d5a55e7728b, Swift ec5bee8)
Target: x86_64-unknown-linux-gnu

Additional information

No response

@jamieQ jamieQ added bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. triage needed This issue needs more specific labels labels Dec 10, 2024
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. triage needed This issue needs more specific labels
Projects
None yet
Development

No branches or pull requests

1 participant