[M3devel] FloatMode

Jay K jay.krell at cornell.edu
Tue Jan 12 20:13:25 CET 2010


Instead of the small evil of #ifdefs, we had two large evils:
 
 
 - cloning headers, fragile, tedious, error-prone 
   Though I think generally safe, *if* done *extremely* *carefully* and *correctly*. There is a need for the underlying system to not change. The commercial systems all do that well. 64bit FreeBSD seems to have a poor record at least. NetBSD changes the symbol names maybe often. etc.
 
 
 - cloning nearly identical Modula-3 code many times

 
The second could have been reduced, by making directories keyed by processor 
architecture or kernel, instead of architecture_kernel pairs.
 
 
The first could have been reduced a lot by limiting it to only what we use.
That was what I did at first with Cygwin.
But still.
 
 
By using #ifdefs we have gained a lot of portability and thrown away many lines of code.
 
 
A C generating backend will increase portability another very big step.
 
 
 - Jay



----------------------------------------
> From: jay.krell at cornell.edu
> To: hendrik at topoi.pooq.com; m3devel at elegosoft.com
> Date: Tue, 12 Jan 2010 19:02:49 +0000
> Subject: Re: [M3devel] FloatMode
>
>
> That's *really* *not* a good thing.
>
> - Jay
>
>
> ----------------------------------------
>> Date: Tue, 12 Jan 2010 13:55:21 -0500
>> From: hendrik at topoi.pooq.com
>> To: m3devel at elegosoft.com
>> Subject: Re: [M3devel] FloatMode
>>
>> On Tue, Jan 12, 2010 at 01:33:59PM -0500, Tony Hosking wrote:
>>> On 11 Jan 2010, at 23:55, Jay K wrote:
>>>>
>>>> Probably like other per-platform code, this should be done in #ifdefed C.
>>>
>>> Agreed... does that mean you will bite? ;-)
>>
>> I seem to remember an ad for Modula 3 once that went something like
>> lines of code, and not a single ifdef!
>>
>> -- hendrik 		 	   		  


More information about the M3devel mailing list