[M3devel] GenerateCGMain "plan" .. unreachable code...

Jay K jay.krell at cornell.edu
Fri Sep 14 13:34:37 CEST 2012


http://modula3.elegosoft.com/cgi-bin/cvsweb.cgi/cm3/m3-sys/cm3/src/Builder.m3?rev=1.1.1.1;content-type=text%2Fplain

PROCEDURE GenerateCGMain (s: State;  Main_O: TEXT) =
  VAR
...    plan     : [0..3] := 0;
.. no uses of "plan" ...
if plan = 2

that can't happen.
Clearly the point was to check the backend mode. or set plan := ORD(mode) (no point in that; elsewhere they do that and increment by 4 if bootstrapping..kind of messy this code..it seems it could be better factored...)

Might as well we chuck the option m3main_in_c and always do it that way?

 - Jay


 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20120914/b3e88265/attachment-0001.html>


More information about the M3devel mailing list