Home
last modified time | relevance | path

Searched full:derive (Results 1 – 25 of 302) sorted by relevance

12345678910>>...13

/linux/rust/zerocopy-derive/
H A Dlib.rs11 //! Derive macros for [zerocopy]'s traits.
52 mod derive;
71 // help: required by the derive of FromBytes
80 /// Defines a derive function named `$outer` which parses its input
86 macro_rules! derive {
130 derive!(KnownLayout => derive_known_layout => crate::derive::known_layout::derive);
131 derive!(Immutable => derive_immutable => crate::derive
48 mod derive; global() module
81 macro_rules! derive { global() macro
[all...]
H A DREADME.md1 # `zerocopy-derive`
3 These source files come from the Rust `zerocopy-derive` crate, version v0.8.62
H A Drepr.rs30 #[cfg_attr(test, derive(Copy, Clone, Debug))]
40 #[cfg_attr(test, derive(Copy, Clone, Debug, Eq, PartialEq))]
48 #[derive(Copy, Clone)]
49 #[cfg_attr(test, derive(Debug, Eq, PartialEq))]
66 #[cfg_attr(test, derive(Copy, Clone, Debug, Eq, PartialEq))]
160 "cannot derive `Unaligned` on type with alignment greater than 1", in unaligned_validate_no_align_gt_1()
270 #[derive(Copy, Clone, PartialEq, Eq)]
271 #[cfg_attr(test, derive(Debug))]
294 #[cfg_attr(test, derive(Debug, Eq, PartialEq))]
305 #[cfg_attr(test, derive(Cop
[all...]
/linux/rust/syn/gen/
H A Dvisit_mut.rs8 #[cfg(any(feature = "full", feature = "derive"))]
16 #[cfg(all(feature = "derive", not(feature = "full")))]
32 #[cfg(any(feature = "derive", feature = "full"))]
33 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
37 #[cfg(any(feature = "derive", feature = "full"))]
38 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
50 #[cfg(any(feature = "derive", feature = "full"))]
51 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
55 #[cfg(any(feature = "derive", feature = "full"))]
56 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
[all …]
H A Dvisit.rs8 #[cfg(any(feature = "full", feature = "derive"))]
16 #[cfg(all(feature = "derive", not(feature = "full")))]
31 #[cfg(any(feature = "derive", feature = "full"))]
32 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
36 #[cfg(any(feature = "derive", feature = "full"))]
37 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
49 #[cfg(any(feature = "derive", feature = "full"))]
50 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
54 #[cfg(any(feature = "derive", feature = "full"))]
55 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
[all …]
H A Dfold.rs18 #[cfg(all(feature = "derive", not(feature = "full")))]
30 #[cfg(any(feature = "derive", feature = "full"))]
31 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
35 #[cfg(any(feature = "derive", feature = "full"))]
36 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
48 #[cfg(any(feature = "derive", feature = "full"))]
49 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
53 #[cfg(any(feature = "derive", feature = "full"))]
54 #[cfg_attr(docsrs, doc(cfg(any(feature = "derive", feature = "full"))))]
58 #[cfg(any(feature = "derive", feature = "full"))]
[all …]
H A Deq.rs6 #[cfg(any(feature = "derive", feature = "full"))]
8 #[cfg(any(feature = "derive", feature = "full"))]
11 #[cfg(any(feature = "derive", feature = "full"))]
18 #[cfg(any(feature = "derive", feature = "full"))]
21 #[cfg(any(feature = "derive", feature = "full"))]
39 #[cfg(any(feature = "derive", feature = "full"))]
42 #[cfg(any(feature = "derive", feature = "full"))]
50 #[cfg(any(feature = "derive", feature = "full"))]
53 #[cfg(any(feature = "derive", feature = "full"))]
61 #[cfg(any(feature = "derive", feature = "full"))]
[all …]
H A Dclone.rs7 #[cfg(any(feature = "derive", feature = "full"))]
17 #[cfg(any(feature = "derive", feature = "full"))]
43 #[cfg(any(feature = "derive", feature = "full"))]
55 #[cfg(any(feature = "derive", feature = "full"))]
67 #[cfg(any(feature = "derive", feature = "full"))]
70 #[cfg(any(feature = "derive", feature = "full"))]
77 #[cfg(any(feature = "derive", feature = "full"))]
89 #[cfg(any(feature = "derive", feature = "full"))]
100 #[cfg(any(feature = "derive", feature = "full"))]
112 #[cfg(any(feature = "derive", feature = "full"))]
[all …]
H A Ddebug.rs8 #[cfg(any(feature = "derive", feature = "full"))]
18 #[cfg(any(feature = "derive", feature = "full"))]
25 #[cfg(any(feature = "derive", feature = "full"))]
50 #[cfg(any(feature = "derive", feature = "full"))]
62 #[cfg(any(feature = "derive", feature = "full"))]
74 #[cfg(any(feature = "derive", feature = "full"))]
89 #[cfg(any(feature = "derive", feature = "full"))]
101 #[cfg(any(feature = "derive", feature = "full"))]
112 #[cfg(any(feature = "derive", feature = "full"))]
124 #[cfg(any(feature = "derive", feature = "full"))]
[all …]
H A Dhash.rs6 #[cfg(any(feature = "derive", feature = "full"))]
9 #[cfg(any(feature = "derive", feature = "full"))]
19 #[cfg(any(feature = "derive", feature = "full"))]
44 #[cfg(any(feature = "derive", feature = "full"))]
56 #[cfg(any(feature = "derive", feature = "full"))]
68 #[cfg(any(feature = "derive", feature = "full"))]
85 #[cfg(any(feature = "derive", feature = "full"))]
96 #[cfg(any(feature = "derive", feature = "full"))]
108 #[cfg(any(feature = "derive", feature = "full"))]
120 #[cfg(any(feature = "derive", feature = "full"))]
[all …]
/linux/rust/syn/
H A Dlib.rs23 //! - **Derives** — Of particular interest to derive macros is
25 //! derive macro. An example below shows using this type in a library that can
26 //! derive implementations of a user-defined trait.
53 //! # Example of a derive macro
55 //! The canonical derive macro using Syn looks like this. We write an ordinary
57 //! the trait we are deriving. Any time that derive appears in the user's code,
99 //! of a derive macro. The example derives a `HeapSize` trait which computes an
111 //! The derive macro allows users to write `#[derive(HeapSize)]` on data
116 //! #[derive(HeapSize)]
136 //! #[derive(HeapSize)]
[all …]
H A Dderive.rs13 #[cfg_attr(docsrs, doc(cfg(feature = "derive")))]
31 #[cfg_attr(docsrs, doc(cfg(feature = "derive")))]
41 #[cfg_attr(docsrs, doc(cfg(feature = "derive")))]
51 #[cfg_attr(docsrs, doc(cfg(feature = "derive")))]
61 #[cfg_attr(docsrs, doc(cfg(feature = "derive")))]
72 use crate::derive::{Data, DataEnum, DataStruct, DataUnion, DeriveInput};
213 use crate::derive::{Data, DeriveInput};
H A Dty.rs23 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
96 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
107 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
122 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
132 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
141 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
149 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
157 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
165 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
175 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
[all …]
H A Dattr.rs57 /// example `#[derive(Copy)]` or `#[precondition(x < 5)]`.
68 /// #[derive(Copy, Clone)]
174 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
186 /// For example this would return the `test` in `#[test]`, the `derive` in
187 /// `#[derive(Copy)]`, and the `path` in `#[path = "sys/windows.rs"]`.
446 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
462 /// A meta list is like the `derive(Copy)` in `#[derive(Copy)]`.
474 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
478 /// A structured list within an attribute, like `derive(Copy, Clone)`.
487 /// A structured list within an attribute, like `derive(Copy, Clone)`.
[all …]
H A Ddata.rs13 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
36 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
53 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
62 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
117 /// The following is a simplistic [`Clone`] derive for structs. (A more
185 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
H A Dgenerics.rs27 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
45 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
60 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
71 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
84 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
275 doc(cfg(all(any(feature = "full", feature = "derive"), feature = "printing")))
283 doc(cfg(all(any(feature = "full", feature = "derive"), feature = "printing")))
291 doc(cfg(all(any(feature = "full", feature = "derive"), feature = "printing")))
356 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
402 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
[all …]
H A Dpath.rs15 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
111 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
140 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
175 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
201 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
213 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
225 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
236 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
248 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
275 #[cfg_attr(docsrs, doc(cfg(any(feature = "full", feature = "derive"))))]
H A Dparse_quote.rs153 #[cfg(any(feature = "full", feature = "derive"))]
158 #[cfg(any(feature = "full", feature = "derive"))]
169 #[cfg(any(feature = "full", feature = "derive"))]
180 #[cfg(any(feature = "full", feature = "derive"))]
/linux/rust/zerocopy/src/
H A Dlib.rs64 //! You should generally derive these marker traits whenever possible.
104 //! - **`derive`**
105 //! Provides derives for the core marker traits via the `zerocopy-derive`
107 //! necessary to depend on `zerocopy-derive` directly.
110 //! depend on both `zerocopy` and `zerocopy-derive` in your `Cargo.toml`,
112 //! so, do *not* enable the `derive` feature, and list both dependencies in
118 //! zerocopy-derive = "0.X"
122 //! one of your dependencies enables zerocopy's `derive` feature, import
327 // This is a hack to allow zerocopy-derive derives to work in this crate. They
330 #[cfg(any(feature = "derive", tes
[all...]
H A Dsplit_at.rs20 /// For a `repr(C, packed)` or `repr(C, packed(N))` struct, the derive wraps
29 /// [`#[derive(SplitAt)]`][derive]; e.g.:
33 /// #[derive(SplitAt, KnownLayout)]
44 /// This derive performs a sophisticated, compile-time safety analysis to
53 /// #[derive(FromBytes, IntoBytes, KnownLayout, SplitAt)]
78 #[cfg_attr(feature = "derive", doc = "[derive]: zerocopy_derive::SplitAt")]
80 not(feature = "derive"),
81 doc = concat!("[derive]
[all...]
/linux/drivers/gpu/drm/vmwgfx/
H A Dvmwgfx_binding.h86 * @bi: struct vmw_ctx_bindinfo we derive from.
97 * @bi: struct vmw_ctx_bindinfo we derive from.
108 * @bi: struct vmw_ctx_bindinfo we derive from.
125 * @bi: struct vmw_ctx_bindinfo we derive from.
138 * @bi: struct vmw_ctx_bindinfo we derive from.
153 * @bi: struct vmw_ctx_bindinfo we derive from.
168 * @bi: struct vmw_ctx_bindinfo we derive from.
209 * @bi: struct vmw_ctx_bindinfo we derive from.
/linux/rust/proc-macro2/
H A Dmarker.rs9 #[derive(Copy, Clone)]
12 derive(PartialEq, Eq)
/linux/rust/zerocopy-derive/derive/
H A Dknown_layout.rs160 // the helper struct we are generating, not the derive target in derive_known_layout_for_repr_c_struct()
176 // resolves to the derive target type, not the helper struct we are in derive_known_layout_for_repr_c_struct()
195 // SAFETY: This has the same layout as the derive target type, in derive_known_layout_for_repr_c_struct()
226 // on the derive target type (both by using the same tokens, and in derive_known_layout_for_repr_c_struct()
229 // to have the same layout as the derive target type, except in derive_known_layout_for_repr_c_struct()
252 pub(crate) fn derive(ctx: &Ctx, _top_level: Trait) -> Result<TokenStream, Error> { in derive()
250 pub(crate) fn derive(ctx: &Ctx, _top_level: Trait) -> Result<TokenStream, Error> { derive() function
/linux/rust/pin-init/examples/
H A Dbig_struct_in_place.rs6 #[derive(Debug)]
17 #[derive(Debug)]
/linux/rust/
H A Dbindgen_parameters74 --with-derive-custom-struct .*=MaybeZeroable
75 --with-derive-custom-union .*=MaybeZeroable

12345678910>>...13