File tree Expand file tree Collapse file tree 3 files changed +20
-1
lines changed Expand file tree Collapse file tree 3 files changed +20
-1
lines changed Original file line number Diff line number Diff line change 56
56
with :
57
57
components : rust-src
58
58
- name : Enable type layout randomization
59
- run : echo RUSTFLAGS=${RUSTFLAGS}\ -Zrandomize-layout >> $GITHUB_ENV
59
+ run : echo RUSTFLAGS=${RUSTFLAGS}\ -Zrandomize-layout\ --cfg=randomize_layout >> $GITHUB_ENV
60
60
- run : cargo check
61
61
env :
62
62
RUSTFLAGS : --cfg procmacro2_nightly_testing ${{env.RUSTFLAGS}}
78
78
env :
79
79
RUSTFLAGS : -Z allow-features= --cfg procmacro2_backtrace ${{env.RUSTFLAGS}}
80
80
81
+ layout :
82
+ name : Layout
83
+ needs : pre_ci
84
+ if : needs.pre_ci.outputs.continue
85
+ runs-on : ubuntu-latest
86
+ timeout-minutes : 45
87
+ steps :
88
+ - uses : actions/checkout@v4
89
+ - uses : dtolnay/rust-toolchain@nightly
90
+ with :
91
+ components : rust-src
92
+ - run : cargo test --test test_size
93
+ - run : cargo test --test test_size --features span-locations
94
+ - run : cargo test --test test_size --no-default-features
95
+ - run : cargo test --test test_size --no-default-features --features span-locations
96
+
81
97
msrv :
82
98
name : Rust 1.56.0
83
99
needs : pre_ci
Original file line number Diff line number Diff line change @@ -57,6 +57,7 @@ fn main() {
57
57
println ! ( "cargo:rustc-check-cfg=cfg(procmacro2_backtrace)" ) ;
58
58
println ! ( "cargo:rustc-check-cfg=cfg(procmacro2_nightly_testing)" ) ;
59
59
println ! ( "cargo:rustc-check-cfg=cfg(procmacro2_semver_exempt)" ) ;
60
+ println ! ( "cargo:rustc-check-cfg=cfg(randomize_layout)" ) ;
60
61
println ! ( "cargo:rustc-check-cfg=cfg(span_locations)" ) ;
61
62
println ! ( "cargo:rustc-check-cfg=cfg(super_unstable)" ) ;
62
63
println ! ( "cargo:rustc-check-cfg=cfg(wrap_proc_macro)" ) ;
Original file line number Diff line number Diff line change
1
+ #![ cfg( not( randomize_layout) ) ]
2
+
1
3
extern crate proc_macro;
2
4
3
5
use std:: mem;
You can’t perform that action at this time.
0 commit comments