[M3devel] Integer literals

hendrik at topoi.pooq.com hendrik at topoi.pooq.com
Tue Jan 12 18:00:04 CET 2010


On Tue, Jan 12, 2010 at 06:55:27AM +0000, Jay K wrote:
> 
> TYPE Int1 = BITS 32, unsigned, integer, trap overflow;
> 
> TYPE Int2 = BITS 64, signed, integer, silent overflow;
> 
> TYPE Float1 = BITS 64, floating point, signed, mantissa 53, exponent 10;
> 
> TYPE Float2 = BITS 128, floating point, signed, mantissa 106, exponent 20;
> 
>  
> 
> and then provide just a few "canned" "popular" types so that
> 
> a lot of code can interoperate with a lot of code, but if a programmer
> 
> really needs something else, he has a chance of defining it.
> 
>  
> 
> Or maybe we can only define what is efficient in hardware, but still
> 
> do so with a syntax like this??

That resembles the approach of C--.  You have to explicitly define the 
precision, byte sex, etc. of your data, and the compiler refuses your 
program if it doesn't match what the machine provides.

-- hendrik



More information about the M3devel mailing list