検索

phrase: max: clip:
target: order:
Results of 1 - 10 of about 193 for derive (0.029 sec.)
デバッグ - Rust By Example 日本語版 15623
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... れを簡略化します。 すべての 型は fmt::Debug の実装を derive 、(すなわち自動で作成)することができるためです。 ... ことができません。 struct UnPrintable(i32); // The `derive` attribute automatically creates the implementatio ... ake this `struct` printable with `fmt::Debug`. // `derive`アトリビュートは、 // この構造体を`fmt::Debug`でプ ...
https://man.plustar.jp/rust/example/hello/print/print_debug.html - [similar]
継承(Derive) - Rust By Example 日本語版 11788
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... ) Rust Coal Navy Ayu Rust By Example 日本語版 継承(Derive) コンパイラには、 [#derive] アトリビュート を用いる ... 同名のトレイトを手動で実装することも可能です。 以下はderive可能なトレイトの一覧です。 型の比較に関連するトレイト ... ompared // `Centimeters`は比較可能なタプルになる #[derive(PartialEq, PartialOrd)] struct Centimeters(f64); / ...
https://man.plustar.jp/rust/example/trait/derive.html - [similar]
Rust By Example 日本語版 9528
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... れを簡略化します。 すべての 型は fmt::Debug の実装を derive 、(すなわち自動で作成)することができるためです。 ... ことができません。 struct UnPrintable(i32); // The `derive` attribute automatically creates the implementatio ... ake this `struct` printable with `fmt::Debug`. // `derive`アトリビュートは、 // この構造体を`fmt::Debug`でプ ...
https://man.plustar.jp/rust/example/print.html - [similar]
Combinators: map - Rust By Example 日本語版 8311
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... 果たしているのがわかります。 #![allow(dead_code)] #[derive(Debug)] enum Food { Apple, Carrot, Potato } #[deri ... ve(Debug)] struct Peeled(Food); #[derive(Debug)] struct Chopped(Food); #[derive(Debug)] str ...
https://man.plustar.jp/rust/example/error/option_unwrap/map.html - [similar]
key型の変種 - Rust By Example 日本語版 8311
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... h を実装するのは簡単です。以下の一行で済みます。 #[derive(PartialEq, Eq, Hash)] 後はコンパイラがよしなにして ... std::collections::HashMap; // Eq requires that you derive PartialEq on the type. // Eqトレイトを使用する時は ... 、PartialEqをderiveする必要があります。 #[derive(PartialEq, Eq, Hash)] ...
https://man.plustar.jp/rust/example/std/hash/alt_key_types.html - [similar]
ディスプレイ - Rust By Example 日本語版 7790
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... / A structure holding two numbers. `Debug` will be derived so the results can // be contrasted with `Display ... 造体です。出力を`Display`と比較するため`Debug` // をDeriveしています #[derive(Debug)] struct MinMax(i64, i64); ... ィールドに名前をつけれる様な構造体を定義しましょう #[derive(Debug)] struct Point2D { x: f64, y: f64, } // Simi ...
https://man.plustar.jp/rust/example/hello/print/print_display.html - [similar]
構造体 - Rust By Example 日本語版 7790
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... 照は`Borrowed`自体よりも長生きでなくてはならない。 #[derive(Debug)] struct Borrowed<'a>(&'a i32); // Similarly ... こでも参照は構造体よりも長生きでなくてはならない。 #[derive(Debug)] struct NamedBorrowed<'a> { x: &'a i32, y: ... 32`、あるいは`i32`への参照のいずれかとなる列挙型 #[derive(Debug)] enum Either<'a> { Num(i32), Ref(&'a i32), ...
https://man.plustar.jp/rust/example/scope/lifetime/struct.html - [similar]
幽霊型パラメータ - Rust By Example 日本語版 7442
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... ネリックなタプル構造体。2つ目のパラメータは幽霊型 #[derive(PartialEq)] // Allow equality test for this type. ... with hidden parameter `B`. // 同様に構造体を定義 #[derive(PartialEq)] // Allow equality test for this type. ... ields: {}", // _struct1 == _struct2); } 参照 継承( Derive ) , 構造体 , タプル 関連キーワード: 幽霊 , パラメー ...
https://man.plustar.jp/rust/example/generics/phantom.html - [similar]
テストケース: 単位を扱う - Rust By Example 日本語版 7268
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... ypes. /// 単位を定義するため、空の列挙型を作成。 #[derive(Debug, Clone, Copy)] enum Inch {} #[derive(Debug, ... ははじめから`Clone`、`Copy`トレイトを持っている。 #[derive(Debug, Clone, Copy)] struct Length<Unit>(f64, Phan ...
https://man.plustar.jp/rust/example/generics/phantom/testcase_units.html - [similar]
FromおよびInto - Rust By Example 日本語版 6747
Introduction 1. Hello World ❱ 1.1. コメント 1.2. フォーマットしてプリント ❱ 1.2.1. デバッグ 1.2. ... ライフタイム 15.4.9. 省略 16. トレイト ❱ 16.1. 継承(Derive) 16.2. Returning Traits with dyn 16.3. 演算子のオー ... すれば同じように行えます。 use std::convert::From; #[derive(Debug)] struct Number { value: i32, } impl From<i3 ... は小さなトレードオフです。 use std::convert::From; #[derive(Debug)] struct Number { value: i32, } impl From<i3 ...
https://man.plustar.jp/rust/example/conversion/from_into.html - [similar]
PREV 1 2 3 4 5 6 7 8 9 10 NEXT