[M3devel] quick question for the Modula-3 ether... LONGFLOAT??

Mika Nystrom mika at async.caltech.edu
Mon Apr 13 00:22:23 CEST 2009


It seems a bit more common a term than I would have thought from
someone's making a mistake.

I am talking about things like this.  In the stubgen sources, there are
two interfaces: Value.i3 and Type.i3.

Not the only place I've seen it in Modula-3.

Value.i3 has:

TYPE 
  T <: ROOT;
  (* Ordinal | Float | LongFloat | Extended | ArrayOrRecord | Set | 
     Text | Null *)

    Ordinal = T OBJECT ord: INTEGER END;
    (* ORD(the value) *)

    Float = T OBJECT val: REAL END;          (* XXX *)

    LongFloat = T OBJECT val: LONGREAL END;  (* XXX *)

    Extended  = T OBJECT val: EXTENDED END;

...

Type.i3 has:

TYPE
  T <: OBJECT name: Qid; visited := FALSE; brandsOK := TRUE  END;

  (* Ordinal | Real | LongReal | Extended | Reference  | Array 
  | Packed | Record | Set | Procedure  *)

  Ordinal =  T BRANDED OBJECT END; (* Enumeration | Subrange *)

  (* ... *)

  Real = T BRANDED OBJECT END;        (* YYY *)

  LongReal = T BRANDED OBJECT END;    (* YYY *)

  Extended = T BRANDED OBJECT END;

...

Is there a reason or is this just inconsistent crud from before the
glaciers came thru?

     Mika


Jay writes:
>--_eaf98d33-2bbc-4e5b-8afc-bc1f32079c51_
>Content-Type: text/plain; charset="iso-8859-1"
>Content-Transfer-Encoding: quoted-printable
>
>
>1) I'm sure it is a natural term to all the other programmers=2C easy mista=
>ke to make.
>
>=20
>
>2) There in fact this natural need to come up with alternate names.
>
>You know=2C if you read the compiler and runtime source=2C you see things c=
>alled Type and/or Tipe=2C not just Type=2C because Type (or at least TYPE) =
>is already a reserved word if you write "metacode" dealing with types=2C yo=
>u can't use that name.
>
>=20
>
>In that vein there are some public m3core modules for dealing with floats/r=
>eals/whatever and they might use names like this.
>
>=20
>
> - Jay
>
>
>=20
>> To: m3devel at elegosoft.com
>> Date: Sun=2C 12 Apr 2009 13:05:49 -0700
>> From: mika at async.caltech.edu
>> Subject: [M3devel] quick question for the Modula-3 ether... LONGFLOAT??
>>=20
>>=20
>> Does anyone out there have any idea why a lot of bits of Modula-3
>> refer to something called "LONGFLOAT" or "LongFloat". I just checked
>> Wirth=2C and Modula-2 used "REAL" as well so it doesn't seem like
>> LONGREAL would ever have been called "LONGFLOAT".
>>=20
>> Is LONGFLOAT/LongFloat of any significance or is it OK to
>> search-and-replace it away with LONGREAL/LongReal everywhere?
>>=20
>> (I'm talking about things like the emacs macro package as well as
>> all over m3tk...)
>>=20
>> Mika
>
>--_eaf98d33-2bbc-4e5b-8afc-bc1f32079c51_
>Content-Type: text/html; charset="iso-8859-1"
>Content-Transfer-Encoding: quoted-printable
>
><html>
><head>
><style>
>.hmmessage P
>{
>margin:0px=3B
>padding:0px
>}
>body.hmmessage
>{
>font-size: 10pt=3B
>font-family:Verdana
>}
></style>
></head>
><body class=3D'hmmessage'>
>1) I'm sure it is a natural term to all the&nbsp=3Bother programmers=2C eas=
>y mistake to make.<BR>
>&nbsp=3B<BR>
>2) There in fact this&nbsp=3Bnatural need to come up with alternate names.<=
>BR>
>You know=2C if you read the compiler&nbsp=3Band runtime source=2C you see t=
>hings called Type and/or Tipe=2C not just Type=2C because Type (or at least=
> TYPE) is already a reserved word if you write&nbsp=3B"metacode" dealing wi=
>th types=2C you can't use that name.<BR>
>&nbsp=3B<BR>
>In that&nbsp=3Bvein there are some&nbsp=3Bpublic m3core modules for dealing=
> with floats/reals/whatever and they&nbsp=3Bmight use names like this.<BR>
>&nbsp=3B<BR>
>&nbsp=3B- Jay<BR><BR><BR>&nbsp=3B<BR>&gt=3B To: m3devel at elegosoft.com<BR>&g=
>t=3B Date: Sun=2C 12 Apr 2009 13:05:49 -0700<BR>&gt=3B From: mika at async.cal=
>tech.edu<BR>&gt=3B Subject: [M3devel] quick question for the Modula-3 ether=
>... LONGFLOAT??<BR>&gt=3B <BR>&gt=3B <BR>&gt=3B Does anyone out there have =
>any idea why a lot of bits of Modula-3<BR>&gt=3B refer to something called =
>"LONGFLOAT" or "LongFloat". I just checked<BR>&gt=3B Wirth=2C and Modula-2 =
>used "REAL" as well so it doesn't seem like<BR>&gt=3B LONGREAL would ever h=
>ave been called "LONGFLOAT".<BR>&gt=3B <BR>&gt=3B Is LONGFLOAT/LongFloat of=
> any significance or is it OK to<BR>&gt=3B search-and-replace it away with =
>LONGREAL/LongReal everywhere?<BR>&gt=3B <BR>&gt=3B (I'm talking about thing=
>s like the emacs macro package as well as<BR>&gt=3B all over m3tk...)<BR>&g=
>t=3B <BR>&gt=3B Mika<BR></body>
></html>=
>
>--_eaf98d33-2bbc-4e5b-8afc-bc1f32079c51_--



More information about the M3devel mailing list