So the proper way to ascertain that something gets side effects run is something like this, instead?
lambda(mixed x){}(1/0);
If not, how about adding something like a method assert() (under some other name, perhaps) which does ascertains that whatever expressions passed don't get optimised away, or some kind of optimiser override, for the rare case where you don't care storing something, but want a validation / error throwing side effect of evaluating some code with no other side effects?