View Single Post
  #8  
Old 02-28-2019, 04:51
chants chants is online now
VIP
 
Join Date: Jul 2016
Posts: 836
Rept. Given: 47
Rept. Rcvd 52 Times in 32 Posts
Thanks Given: 742
Thanks Rcvd at 1,148 Times in 531 Posts
chants Reputation: 52
However, if the referenced value (b) is unused, in all caller contexts which invoke this function, then theoretically
Quote:
b += 4
can be optimized out. Of course with reflection or exporting that would be somewhat impossible to deduce but these sorts of assumptions are more complicated issues even the compiler has to make decisions about and usually documented vaguely somewhere as to what guarantees are provided.
Reply With Quote