Reapply "Mark Crucible-related hook functions as #[inline(never)]"#203
Reapply "Mark Crucible-related hook functions as #[inline(never)]"#203RyanGlScott merged 2 commits intomasterfrom
#[inline(never)]"#203Conversation
This re-applies the changes from #154, which were omitted from #200 due to an oversight. It is a bit unclear whether or not `#[inline(never)]` is strictly necessary here (see #153 (comment)), but better to be on the safe side. To make it more likely that we will remember to apply this change in the future, I have started a "Notes" section in `libs/Patches.md` that very explicitly calls out the needs for `#[inline(never)]`, and I have cited this note from the relevant patch descriptions. Going forward, we can use this "Notes" section to describe other aspects of patches that require more in-depth explanations that what can be afforded in the brief patch descriptions.
48089ec to
740fff4
Compare
In the past, we have forgotten to reapply updates to particular patches (see #153 (comment) for one example). This adds a new documentation convention to `libs/Patches.md` to make this less likely to occur in the future. Whenever we update the implementation of an existing patch, we now add an *Update* line to the patch description that summarizes what was updated. Then, when the overall patch is reapplied during an upgrade to a new Rust toolchain version, we fold the changes from each *Update* into the main patch, and then we remove the *Update* line entirely.
|
Based on @qsctr's suggestion in #153 (comment), I've added a new convention to the This is in addition to the Notes system. Perhaps having both is a bit overkill, but I can foresee different use cases for each mechanism: not all patch updates will necessarily be nuanced enough to deserve their own Note, and it's conceivable that we may want to write standalone Notes in the future without needing a corresponding update to a patch. |
This re-applies the changes from #154, which were omitted from #200 due to an oversight. It is a bit unclear whether or not
#[inline(never)]is strictly necessary here (see #153 (comment)), but better to be on the safe side.To make it more likely that we will remember to apply this change in the future, I have started a "Notes" section in
libs/Patches.mdthat very explicitly calls out the needs for#[inline(never)], and I have cited this note from the relevant patch descriptions. Going forward, we can use this "Notes" section to describe other aspects of patches that require more in-depth explanations that what can be afforded in the brief patch descriptions.