File tree Expand file tree Collapse file tree 4 files changed +10
-5
lines changed
crates/wasmparser/src/validator Expand file tree Collapse file tree 4 files changed +10
-5
lines changed Original file line number Diff line number Diff line change 4040 EOF
4141
4242 # Deny warnings on CI to keep our code warning-free as it lands in-tree.
43- echo RUSTFLAGS="-D warnings" >> "$GITHUB_ENV"
43+ echo RUSTFLAGS="-D warnings $RUSTFLAGS " >> "$GITHUB_ENV"
4444
4545 - run : rustup target add wasm32-wasip2
4646 if : inputs.toolchain != 'msrv'
Original file line number Diff line number Diff line change @@ -132,6 +132,12 @@ jobs:
132132 rust : stable
133133 env :
134134 RUST_BACKTRACE : 1
135+ # test the 'try_op' feature
136+ - os : ubuntu-latest
137+ rust : stable
138+ env :
139+ RUSTFLAGS : --cfg=debug_check_try_op
140+ flags : -F wasmparser/try-op
135141 env : ${{ matrix.env || fromJSON('{}') }}
136142 steps :
137143 - uses : actions/checkout@v6
@@ -155,7 +161,6 @@ jobs:
155161 - run : cargo test -p wasm-smith --features wasmparser
156162 - run : cargo test -p wasm-smith --features component-model
157163 - run : cargo test --locked -p wasmparser --features try-op
158- - run : cargo test --locked -F wasmparser/try-op
159164
160165 test_capi :
161166 name : Test the C API
Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ rust-2024-incompatible-pat = 'warn'
6666missing-unsafe-on-extern = ' warn'
6767unsafe-op-in-unsafe-fn = ' warn'
6868
69- unexpected_cfgs = { level = ' warn' , check-cfg = [' cfg(fuzzing)' ] }
69+ unexpected_cfgs = { level = ' warn' , check-cfg = [' cfg(fuzzing)' , ' cfg(debug_check_try_op) ' ] }
7070
7171[workspace .lints .clippy ]
7272# The default set of lints in Clippy is viewed as "too noisy" right now so
Original file line number Diff line number Diff line change @@ -122,9 +122,9 @@ impl<T: WasmModuleResources> FuncValidator<T> {
122122 reader. set_features ( self . validator . features ) ;
123123 }
124124 while !reader. eof ( ) {
125- // In a debug build, verify that `rollback` successfully returns the
125+ // In a `debug_check_try_op` build, verify that `rollback` successfully returns the
126126 // validator to its previous state after each (valid or invalid) operator.
127- #[ cfg( all( debug_assertions , feature = "try-op" ) ) ]
127+ #[ cfg( all( debug_check_try_op , feature = "try-op" ) ) ]
128128 {
129129 let snapshot = self . validator . clone ( ) ;
130130 let op = reader. peek_operator ( & self . visitor ( reader. original_position ( ) ) ) ?;
You can’t perform that action at this time.
0 commit comments