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

Arc downcast #50836

Merged
merged 4 commits into from
Jun 1, 2018
Merged

Arc downcast #50836

merged 4 commits into from
Jun 1, 2018

Commits on May 31, 2018

  1. Add implementations for Any + Send + Sync

    Implement `is`, `downcast_ref`, `downcast_mut` and `Debug` for
    `Any + Send + Sync`.
    jsgf committed May 31, 2018
    Configuration menu
    Copy the full SHA
    72433e1 View commit details
    Browse the repository at this point in the history
  2. Implement downcast for Arc<Any + Send + Sync>

    We only need to implement it for `Any + Send + Sync` because in practice
    that's the only useful combination for `Arc` and `Any`.
    
    Implementation for rust-lang#44608 under the `rc_downcast` feature.
    jsgf committed May 31, 2018
    Configuration menu
    Copy the full SHA
    37f5cf5 View commit details
    Browse the repository at this point in the history
  3. Update Arc and Rc to use NonNull::cast to cast the inner pointers

    This avoids an `unsafe` block in each case.
    jsgf committed May 31, 2018
    Configuration menu
    Copy the full SHA
    0c7bf56 View commit details
    Browse the repository at this point in the history
  4. Fix up Any doc examples

    Make the Any+Send+Sync examples use the right trait bounds, and fix a small whitespace issue.
    jsgf committed May 31, 2018
    Configuration menu
    Copy the full SHA
    87c3d7b View commit details
    Browse the repository at this point in the history