mirror of
https://github.com/allankoechke/rust.git
synced 2026-11-30 11:05:36 +00:00
Make comptime functions ineligible for coverage - https://github.com/rust-lang/rust/pull/159777 - https://github.com/rust-lang/rust/pull/161808 --- As reported in https://github.com/rust-lang/rust/pull/161808, the assertion in https://github.com/rust-lang/rust/pull/159777 causes the compiler to ICE when it tries to generate an unused-function record for comptime functions, because comptime functions aren't allowed to have a symbol name. This can occur when trying to instrument `core`, for example. Compile-time-only functions don't generate code, so instrumenting them for coverage is useless anyway. This PR therefore makes them ineligible for coverage, which avoids the problem.