home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.misc
- Path: sparky!uunet!cs.utexas.edu!sun-barr!ames!purdue!mentor.cc.purdue.edu!pop.stat.purdue.edu!hrubin
- From: hrubin@pop.stat.purdue.edu (Herman Rubin)
- Subject: Re: languages which allow the introduction of new operators
- Message-ID: <By4EM9.7qn@mentor.cc.purdue.edu>
- Sender: news@mentor.cc.purdue.edu (USENET News)
- Organization: Purdue University Statistics Department
- References: <Bxz8px.FBx@mentor.cc.purdue.edu> <722322705@sheol.UUCP>
- Date: Sun, 22 Nov 1992 13:54:08 GMT
- Lines: 35
-
- In article <722322705@sheol.UUCP> throopw@sheol.UUCP (Wayne Throop) writes:
-
- ...................
-
- e can communicate binary integers across machines
- >: and implementations; the much used notation 0ddddd for octal and
- >: 0xdddddddd for hexadecimal, bad as they are, do this explicitly.
- >
- >So, what does this have to do with the semantic model of the language?
- >What prevents one from converting the floats to binary representation
- >in ascii, transmitting that, reading the result, and doing the
- >inverse conversion?
-
- This will not do the job. The binary representations of floats on
- CRAYs, CYBERs, VAXen, RS/6000s, etc., are all different. Also, these
- are only the representations of floats within the precision of the
- machine. In addition, there is NO remotely standard fixed-point
- binary representation of non-integers which can be communicated.
-
- With integers, we can transmit integers of arbitrary length in decimal,
- octal, or hexadecimal without having any idea of how the hardware/software
- of the machine handles it. We have corresponding facilities for fixed-
- point and floating-point decimals. If someone types in pi to 200 digits,
- there is no problem in understanding what is communicated, whether fixed-point
- or floating-point. But now how do you do this if one is not interested in
- communicating the decimal representation, but the hex or octal?
-
- If one is writing a program, the non-integral constants often should be
- given in octal or hex for various reasons. This means that the language
- in which that program is written must have some way to read them.
- --
- Herman Rubin, Dept. of Statistics, Purdue Univ., West Lafayette IN47907-1399
- Phone: (317)494-6054
- hrubin@snap.stat.purdue.edu (Internet, bitnet)
- {purdue,pur-ee}!snap.stat!hrubin(UUCP)
-