[Mono-devel-list] [PATCH] ilasm problem with float literals like "1e+150"

Steven Brown swbrown at ucsd.edu
Tue Jun 29 02:45:31 EDT 2004


This is a fix for an ilasm case where il generated by monodis can't be 
subsequently parsed.  The problem is in parsing of float literals like 
"1e+150".  NumberHelper only treats it as a float if it sees a '.'.  I 
did a quick hack fix of having it also look for 'e' and 'E' which fixes 
at least that case (are there more ways of representing a float literal?).

Also, while poking around, I noticed monodis doesn't have the cast 
syntax ildasm does for float literals.  E.g., monodis will put "1e+150" 
where ildasm would have put "float64(1e+150)".  Mono does the casts for 
  non-float types.  I'm totally unfamiliar with the il level of things, 
so I'm not sure if this matters.  In case it does, the other patch 
attached has monodis add the missing casts.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mcs-ilasm-NumberHelper-float-swb.patch
Url: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20040628/a9a2b995/attachment.pl 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mono-monodis-typing-swb.patch
Url: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20040628/a9a2b995/attachment-0001.pl 


More information about the Mono-devel-list mailing list