-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Expand set_ptr_value / with_metadata_of docs #131339
Expand set_ptr_value / with_metadata_of docs #131339
Conversation
Rewrite these blobs to explicitly mention the case of a sized operand. The previous made that seem wrong instead of emphasizing it is nothing but a simple cast. Instead, the explanation now emphasizes that the address portion of the argument, together with its provenance, is discarded which previously had to be inferred by the reader. Then an example demonstrates a simple line of incorrect usage based on this idea of provenance.
rustbot has assigned @Mark-Simulacrum. Use |
@bors r+ rollup |
Er, actually, forgot I left a comment. r=me with the below fixed. @bors r- |
@rustbot ready |
@bors r+ rollup In the future, please squash in trivial fix ups to avoid polluting git history (especially in small PRs where the diff isn't any meaningfully shorter to review either way). |
…tation, r=Mark-Simulacrum Expand set_ptr_value / with_metadata_of docs In preparation of a potential FCP, intends to clean up and expand the documentation of this operation. Rewrite these blobs to explicitly mention the case of a sized operand. The previous made that seem wrong instead of emphasizing it is nothing but a simple cast. Instead, the explanation now emphasizes that the address portion of the argument, together with its provenance, is discarded which previously had to be inferred by the reader. Then an example demonstrates a simple line of incorrect usage based on this idea of provenance. Tracking issue: rust-lang#75091
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#122670 (Fix bug where `option_env!` would return `None` when env var is present but not valid Unicode) - rust-lang#131095 (Use environment variables instead of command line arguments for merged doctests) - rust-lang#131339 (Expand set_ptr_value / with_metadata_of docs) - rust-lang#131652 (Move polarity into `PolyTraitRef` rather than storing it on the side) - rust-lang#131675 (Update lint message for ABI not supported) - rust-lang#131681 (Fix up-to-date checking for run-make tests) - rust-lang#131702 (Suppress import errors for traits that couldve applied for method lookup error) - rust-lang#131703 (Resolved python deprecation warning in publish_toolstate.py) - rust-lang#131710 (Remove `'apostrophes'` from `rustc_parse_format`) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#122670 (Fix bug where `option_env!` would return `None` when env var is present but not valid Unicode) - rust-lang#131095 (Use environment variables instead of command line arguments for merged doctests) - rust-lang#131339 (Expand set_ptr_value / with_metadata_of docs) - rust-lang#131652 (Move polarity into `PolyTraitRef` rather than storing it on the side) - rust-lang#131675 (Update lint message for ABI not supported) - rust-lang#131681 (Fix up-to-date checking for run-make tests) - rust-lang#131702 (Suppress import errors for traits that couldve applied for method lookup error) - rust-lang#131703 (Resolved python deprecation warning in publish_toolstate.py) - rust-lang#131710 (Remove `'apostrophes'` from `rustc_parse_format`) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#122670 (Fix bug where `option_env!` would return `None` when env var is present but not valid Unicode) - rust-lang#131095 (Use environment variables instead of command line arguments for merged doctests) - rust-lang#131339 (Expand set_ptr_value / with_metadata_of docs) - rust-lang#131652 (Move polarity into `PolyTraitRef` rather than storing it on the side) - rust-lang#131675 (Update lint message for ABI not supported) - rust-lang#131681 (Fix up-to-date checking for run-make tests) - rust-lang#131702 (Suppress import errors for traits that couldve applied for method lookup error) - rust-lang#131703 (Resolved python deprecation warning in publish_toolstate.py) - rust-lang#131710 (Remove `'apostrophes'` from `rustc_parse_format`) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#131339 - HeroicKatora:set_ptr_value-documentation, r=Mark-Simulacrum Expand set_ptr_value / with_metadata_of docs In preparation of a potential FCP, intends to clean up and expand the documentation of this operation. Rewrite these blobs to explicitly mention the case of a sized operand. The previous made that seem wrong instead of emphasizing it is nothing but a simple cast. Instead, the explanation now emphasizes that the address portion of the argument, together with its provenance, is discarded which previously had to be inferred by the reader. Then an example demonstrates a simple line of incorrect usage based on this idea of provenance. Tracking issue: rust-lang#75091
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#122670 (Fix bug where `option_env!` would return `None` when env var is present but not valid Unicode) - rust-lang#131095 (Use environment variables instead of command line arguments for merged doctests) - rust-lang#131339 (Expand set_ptr_value / with_metadata_of docs) - rust-lang#131652 (Move polarity into `PolyTraitRef` rather than storing it on the side) - rust-lang#131675 (Update lint message for ABI not supported) - rust-lang#131681 (Fix up-to-date checking for run-make tests) - rust-lang#131702 (Suppress import errors for traits that couldve applied for method lookup error) - rust-lang#131703 (Resolved python deprecation warning in publish_toolstate.py) - rust-lang#131710 (Remove `'apostrophes'` from `rustc_parse_format`) r? `@ghost` `@rustbot` modify labels: rollup
In preparation of a potential FCP, intends to clean up and expand the documentation of this operation.
Rewrite these blobs to explicitly mention the case of a sized operand. The previous made that seem wrong instead of emphasizing it is nothing but a simple cast. Instead, the explanation now emphasizes that the address portion of the argument, together with its provenance, is discarded which previously had to be inferred by the reader. Then an example demonstrates a simple line of incorrect usage based on this idea of provenance.
Tracking issue: #75091