Stream: t-compiler/help

Topic: Why is `unsafe_derive_on_repr_packed` a query?

lcnr (May 17 2020 at 14:34, on Zulip):

This is only called from check_unsafety in the same file it is declared, so this should not be necessary for the compile graph.
check_unsafety is only called during analysis

lcnr (May 17 2020 at 14:37, on Zulip):

THis means that check_unsafety should only be called exactly once for each body. As unsafe_derive_on_repr_packed is only called using this body id, it should both be faster and "cleaner" to use a boolean in check_unsafetyitself to prevent duplicates if I am not missing something

lcnr (May 17 2020 at 14:42, on Zulip):

Will just try and implement this myself :sparkles: Let's see if this breaks something

lcnr (May 17 2020 at 14:46, on Zulip):

if I am not missing something

Aaaa, we want to warn once for each impl, not once for each method. There are builtin impls containing multiple methods.

Last update: Sep 27 2020 at 13:30UTC