Open nikomatsakis opened 1 month ago
SalsaIngredient?
I would prefer a term other than Ingredient
because it's already a widely used term and I fear we would start overloading it.
I also think that Update
is implemented by types that aren't ingredients, but are just part of Ingredients
.
Yeah, it is not an ingredient. It is for data structures that can be included in tracked/interned structs but which are not, themselves, tracked/interned structs.
What about SalsaStructMember
?
My understanding of the Update
trait is still very limited but I like the name if it is the trait that must be implemented by every salsa-struct field (maybe SalsaStructField
?)
I like the name SalsaStructField
. Also, as discussed in our sync meeting today, I wonder if we should remove the 'static
fallback (or, more likely, make it "opt-in" with an annotation on the field). The intent would be that deriving SalsaStructField
is more efficient, and it also would make it possible for us to discourage people from using HashMap
and HashSet
(as opposed to FxHashSet
etc) since those can easily lead to non-deterministic results.
The intent would be that deriving SalsaStructField is more efficient
I'm open to trying this on Ruff if we have a PR that adds this requirement to get some data on how painful it is for users.
The name
Update
is highly unintuitive. What this value really means is "safe to store in the salsa database".