------- Additional Comments From rakdver at atrey dot karlin dot mff dot cuni dot cz 2005-05-22 19:56 ------- Subject: Re: missed optimization due with const function and pulling out of loops
> > Because do_something does not have to return, therefore > > get_type2 does not necessarily have to be executed. > > In this case we cannot move the call to get_type2 from > > the loop (since do_something could for example initialize > > some table used internally by get_type2). > > > > This is wrong. > do_something can't write. > it's const. do_something is not const. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21712