You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since multiple closures are generated by macro, the span of which points to the callsite of the macro, we get less useful monomorphic function name lacking the order/index of closures to distinguish them.
A more reliable and simpler way to identify a mono fn is to call Instance::mangled_name. It'll give a unique name like _ZN21standard_proof_simple6verify1f22kani_register_contract17hc0e7d677161f3f51E. But not sure if the mangled name is stable.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Since multiple closures are generated by macro, the span of which points to the callsite of the macro, we get less useful monomorphic function name lacking the order/index of closures to distinguish them.
Here are some attempts to obtain a mono fn name:
Instance::name
:verify::f::kani_register_contract::<(), {closure@tests/standard_proof_simple.rs:3:5: 3:27}>
Instance::trimmed_name
:kani_register_contract::<(), {closure@standard_proof_simple.rs:3:5}>
Unfortunately,
Instance::name
invokesrustc_middle::with_no_trimmed_paths
under the hood, so it'd be not easy to fix.A more reliable and simpler way to identify a mono fn is to call
Instance::mangled_name
. It'll give a unique name like_ZN21standard_proof_simple6verify1f22kani_register_contract17hc0e7d677161f3f51E
. But not sure if the mangled name is stable.Beta Was this translation helpful? Give feedback.
All reactions