検索

phrase: max: clip:
target: order:
Results of 1 - 6 of about 6 for all (0.012 sec.)
Atomics 12813
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... roperly understand in a practical way. If you want all the nitty-gritty details, you should check out C's ... developers face. The C11 memory model is fundamentally about trying to bridge the gap between the semant ... t be great? Compiler Reordering Compilers fundamentally want to be able to do all sorts of complicated tr ... eliminate dead code. In particular, they may radically change the actual order of events, or make events ...
https://man.plustar.jp/rust/nomicon/atomics.html - [similar]
Drop Check 9779
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... ver, what about something like Vec? Vec has to manually drop its elements via pure-library code. In gener ... if the type system isn't careful, it could accidentally make dangling pointers. Consider the following si ... inspector = Inspector(&days); } This program is totally sound and compiles today. The fact that days does ... ry code during its death. This means it can potentially observe that types that are supposed to live as l ...
https://man.plustar.jp/rust/nomicon/dropck.html - [similar]
Send and Sync 8627
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... ing obeys inherited mutability, though. Some types allow you to multiply alias a location in memory while ... ndefined Behavior. Send and Sync are also automatically derived traits. This means that, unlike every oth ... end or Sync types, then it is Send or Sync. Almost all primitives are Send and Sync, and as a consequence ... pretty much all types you'll ever interact with are Send and Sync. ...
https://man.plustar.jp/rust/nomicon/send-and-sync.html - [similar]
Subtyping and Variance 8627
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... lifetimes. Since lifetimes are scopes, we can partially order them based on the contains (outlives) relat ... ds to many: the bigger scope is a subtype of the smaller scope. This does in fact make sense, though. The ... his is that if you expect an &'a u8 , then it's totally fine for me to hand you an &'static u8 , in the s ... way that if you expect an Animal in Java, it's totally fine for me to hand you a Cat. Cats are just Anim ...
https://man.plustar.jp/rust/nomicon/subtyping.html - [similar]
例外安全性 7476
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... く扱い、例外安全を考える必要があるのです。 Vec::push_all Vec::push_all は、特殊化なしに、スライスが確実に効 ... れは単純な実装です。 impl<T: Clone> Vec<T> { fn push_all(&mut self, to_push: &[T]) { self.reserve(to_push.l ... 混ぜてみよう。 もし Rust に Java のような try と finally があったら、コードは こんな感じだったでしょう。 b ... ex] = heap[parent(index)] index = parent(index) finally: heap[index] = elem 基本的な考えは単純です。すなわ ...
https://man.plustar.jp/rust/nomicon/exception-safety.html - [similar]
print.html 7476
はじめに 1. 安全と危険のご紹介 1.1. 安全と危険の相互作用 1.2. Unsafe と連携する 2. データレイアウ ... る事ができます。 このようなコードになるでしょう。 #![allow(unused)] fn main() { use std::cmp::Ordering; uns ... です。例えば、以下の簡単な関数を見てみましょう。 #![allow(unused)] fn main() { fn index(idx: usize, arr: & ... には疑問が残ります。 < を <= に変えてみましょう。 #![allow(unused)] fn main() { fn index(idx: usize, arr: & ... elf.cap { // この例では重要ではありません。 self.reallocate(); } unsafe { ptr::write(self.ptr.offset(self ...
https://man.plustar.jp/rust/nomicon/print.html - [similar]
PREV 1 NEXT