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

Fixes so the compiler can infer msg_send! return types #340

Merged
merged 1 commit into from
Oct 16, 2019
Merged

Fixes so the compiler can infer msg_send! return types #340

merged 1 commit into from
Oct 16, 2019

Commits on Oct 16, 2019

  1. Fixes so the compiler can infer msg_send! return types

    Currently, due to a quirk in Rust's type inference interacting with the
    structure of the msg_send! macro, a () return type will be inferred when
    the compiler cannot otherwise determine the return type. This behavior
    is expected to change, and in the future could resolve to a ! return
    type, which results in undefined behavior.
    
    Linting has previously been added for this in rust-lang/rust#39216, but
    it did not catch these cases due to SSheldon/rust-objc#62. An upcoming
    version of objc will be fixed to stop hiding these errors, at which
    point they will become compile errors.
    
    This change fixes these errors and allows cocoa to compile with the
    fixed version of objc.
    SSheldon committed Oct 16, 2019
    Configuration menu
    Copy the full SHA
    0a1b0d6 View commit details
    Browse the repository at this point in the history