1
Fork 0
Empowering everyone to build reliable and efficient software. Gabriel's commits. https://www.rust-lang.org/
Find a file
许杰友 Jieyou Xu (Joe) b9df376189
Rollup merge of #134606 - RalfJung:ptr-copy-docs, r=Mark-Simulacrum
ptr::copy: fix docs for the overlapping case

Fixes https://github.com/rust-lang/unsafe-code-guidelines/issues/549

As discussed in that issue, it doesn't make any sense for `copy` to read a byte via `src` after it was already written via `dst`. The entire point of this method is that is copies correctly even if they overlap, and that requires always reading any given location before writing it.

Cc `@rust-lang/opsem`
2024-12-27 20:44:11 +08:00
.github ci: use ubuntu 24 instead of latest 2024-12-19 16:02:05 +01:00
compiler Rollup merge of #134606 - RalfJung:ptr-copy-docs, r=Mark-Simulacrum 2024-12-27 20:44:11 +08:00
library Rollup merge of #134606 - RalfJung:ptr-copy-docs, r=Mark-Simulacrum 2024-12-27 20:44:11 +08:00
LICENSES
src Auto merge of #134795 - GuillaumeGomez:rollup-9x8n7pi, r=GuillaumeGomez 2024-12-26 21:04:12 +00:00
tests Rollup merge of #131522 - c410-f3r:unlock-rfc-2011, r=chenyukang 2024-12-26 21:56:47 -05:00
.clang-format
.editorconfig
.git-blame-ignore-revs
.gitattributes
.gitignore
.gitmodules
.ignore
.mailmap
Cargo.lock cargo update 2024-12-22 00:22:56 +00:00
Cargo.toml
CODE_OF_CONDUCT.md
config.example.toml
configure
CONTRIBUTING.md
COPYRIGHT
INSTALL.md
LICENSE-APACHE
license-metadata.json
LICENSE-MIT
README.md
RELEASES.md
REUSE.toml
rust-bors.toml
rustfmt.toml Use field init shorthand where possible 2024-12-17 14:33:10 -08:00
triagebot.toml Belay new reviews for workingjubilee 2024-12-23 11:22:43 -08:00
x
x.ps1
x.py

This is the main source code repository for Rust. It contains the compiler, standard library, and documentation.

Why Rust?

  • Performance: Fast and memory-efficient, suitable for critical services, embedded devices, and easily integrated with other languages.

  • Reliability: Our rich type system and ownership model ensure memory and thread safety, reducing bugs at compile-time.

  • Productivity: Comprehensive documentation, a compiler committed to providing great diagnostics, and advanced tooling including package manager and build tool (Cargo), auto-formatter (rustfmt), linter (Clippy) and editor support (rust-analyzer).

Quick Start

Read "Installation" from The Book.

Installing from Source

If you really want to install from source (though this is not recommended), see INSTALL.md.

Getting Help

See https://www.rust-lang.org/community for a list of chat platforms and forums.

Contributing

See CONTRIBUTING.md.

License

Rust is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0), with portions covered by various BSD-like licenses.

See LICENSE-APACHE, LICENSE-MIT, and COPYRIGHT for details.

Trademark

The Rust Foundation owns and protects the Rust and Cargo trademarks and logos (the "Rust Trademarks").

If you want to use these names or brands, please read the media guide.

Third-party logos may be subject to third-party copyrights and trademarks. See Licenses for details.