GaloisInc / mir-json

Plugin for rustc to dump MIR in JSON format
Apache License 2.0
8 stars 2 forks source link

`saw-rustc`: Skip non-functions in `init_instances_from_tests` without erroring #56

Closed RyanGlScott closed 1 year ago

RyanGlScott commented 1 year ago

crux-rustc makes it an error to annotate non-functions with #[crux::test] attributes. saw-rustc effectivelly annotates everything with that attribute, but we don't want to error when the annotation is applied to a non-function, as typical Rust code will have more things (e.g., statics) than just functions. We now make saw-rustc skip non-functions (thereby not marking them as roots) instead of erroring.

Fixes #55.