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

First draft of a sound ShallowCopy #81

Closed
wants to merge 8 commits into from
Closed

Commits on Nov 29, 2020

  1. First draft of a sound ShallowCopy

    This is trying to address the unsoundness that arises from the current
    version of `ShallowCopy` (see #74). In the process, it also deals with
    the fact that casting between `Inner<.., T, ..>` and `Inner<..,
    ManuallyDrop<T>, ..>` is likely not sound
    (rust-lang/unsafe-code-guidelines#35 (comment)).
    It does not yet work.
    jonhoo committed Nov 29, 2020
    Configuration menu
    Copy the full SHA
    e758133 View commit details
    Browse the repository at this point in the history
  2. New take: use MaybeUninit

    Here is a new take on fixing the soundness bugs with `ShallowCopy`: get
    rid of `ShallowCopy` entirely and instead store the aliased `T` in a
    `MaybeUninit` that we keep two copies of and access unsafely.
    jonhoo committed Nov 29, 2020
    Configuration menu
    Copy the full SHA
    928d94e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    cf53fc0 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    05c3276 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    da137f1 View commit details
    Browse the repository at this point in the history
  6. Some test cleanup

    jonhoo committed Nov 29, 2020
    Configuration menu
    Copy the full SHA
    79d2952 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    787ffb7 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    c14ccce View commit details
    Browse the repository at this point in the history