検索
Results of 41 - 50 of about 58 for struct (0.056 sec.)
- 他言語関数インターフェイス - Rust By Example 日本語版 6498
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
数型の最小限の実装 #[repr(C)] #[derive(Clone, Copy)] struct Complex { re: f32, im: f32, } impl fmt::Debug for...
- https://man.plustar.jp/rust/example/std_misc/ffi.html - [similar]
- create - Rust By Example 日本語版 6498
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
してみることをオススメします。 There is OpenOptions struct that can be used to configure how a file is opened...
- https://man.plustar.jp/rust/example/std_misc/file/create.html - [similar]
- Disambiguating overlapping traits - Rust By Example 日本語版 6498
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
A form with both a UsernameWidget and an AgeWidget struct Form { username: String, age: u8, } impl UsernameW...
- https://man.plustar.jp/rust/example/trait/disambiguating.html - [similar]
- メモリ解放 - Rust By Example 日本語版 6498
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
rop が呼ばれたタイミングが分かるようにしています。 struct Droppable { name: &'static str, } // This trivial...
- https://man.plustar.jp/rust/example/trait/drop.html - [similar]
- テストケース: 連結リスト - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
す。 use crate::List::*; enum List { // Cons: Tuple struct that wraps an element and a pointer to the next no...
- https://man.plustar.jp/rust/example/custom_types/enum/testcase_linked_list.html - [similar]
- 列挙型 - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
素型の中から1つを選ぶような場合に使用します。構造体( struct )の定義を満たすものならば何でも enum の要素型として...
ニット風でもよい PageLoad, PageUnload, // like tuple structs, // タプル風でもよい KeyPress(char), Paste(String...
), // or c-like structures. // C言語スタイルの構造体風でもよい Click { x:...
ent::PageUnload => println!("page unloaded"), // Destructure `c` from inside the `enum`. WebEvent::KeyPress(...
- https://man.plustar.jp/rust/example/custom_types/enum.html - [similar]
- エラー型を定義する - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
の処理を挟むことができます。 #[derive(Debug, Clone)] struct DoubleError; // Generation of an error is complete...
- https://man.plustar.jp/rust/example/error/multiple_error_types/define_error_type... - [similar]
- ?の他の活用法 - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
Result<T, Box<dyn error::Error>>; #[derive(Debug)] struct EmptyVec; impl fmt::Display for EmptyVec { fn fmt(...
} } impl error::Error for EmptyVec {} // The same structure as before but rather than chain all `Results` /...
- https://man.plustar.jp/rust/example/error/multiple_error_types/reenter_question_... - [similar]
- 関連型が必要になる状況 - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
ージで紹介する関連型と呼ばれる機能によって可能です。 struct Container(i32, i32); // A trait which checks if 2...
- https://man.plustar.jp/rust/example/generics/assoc_items/the_problem.html - [similar]
- 関連型 - Rust By Example 日本語版 6396
- Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2.
...
ションの例を関連型を使用して書きなおしてみましょう。 struct Container(i32, i32); // A trait which checks if 2...
- https://man.plustar.jp/rust/example/generics/assoc_items/types.html - [similar]