Core: Fixes around exprOkForSpeculation
Problems:
-
exprOkForSpeculation
has some poorly-explained special cases. - The whole situation around the
has_side_effects
andcan_fail
primop attributes is very confusing, especially as it relates to exceptions.
This is just the exprOkForSpeculation
and has_side_effects
bits of !9359, cleaned up a bit and separated out as they are no longer directly connected to the cbv-primop story.
cc @simonpj
@sgraf812 will likely also be interested