Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #22721
| From | anton@mips.complang.tuwien.ac.at (Anton Ertl) |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: Another OOP thread; everything on the stack is an object |
| Date | 2013-05-17 12:50 +0000 |
| Organization | Institut fuer Computersprachen, Technische Universitaet Wien |
| Message-ID | <2013May17.145017@mips.complang.tuwien.ac.at> (permalink) |
| References | <b4066bda-e458-4763-bbd7-446f9f61377f@g9g2000vbl.googlegroups.com> <kn4dhp$bs6$1@dont-email.me> |
Ron Aaron <rambamist@gmail.com> writes:
>It makes sense to me to "do the right thing" where possible, e.g "+"
>should concatenate strings if the objects on the stack are strings
Really bad example, because this is the wrong thing. + is for adding
numbers. Addition has a number of algebraic properties that string
concatenation does not have; in particular, it forms a commutative
group. I.e., addition is commutative (which string concatenation
obviously is not), and every number has an inverse element
wrt. addition (the negated number). That's not the case for string
concatenation.
>I'm not certain what representation to use for "real" numbers. Since I
>expect to run on Intel and ARM as well (my target platforms are
>Windows/Mac/Linux and Android/iOS, at first) and perhaps other, unknown
>CPUs, I don't know if using the IEEE fp formats is supported across the
>board
It is. Other formats are going the way of 1s-complement. However, I
have come across at least one FPU-less ARM which had broken FP
support.
- anton
--
M. Anton Ertl http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
New standard: http://www.forth200x.org/forth200x.html
EuroForth 2013: http://www.euroforth.org/ef13/
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar
Another OOP thread; everything on the stack is an object Alex McDonald <blog@rivadpm.com> - 2013-05-16 13:37 -0700
Re: Another OOP thread; everything on the stack is an object Bernd Paysan <bernd.paysan@gmx.de> - 2013-05-17 00:09 +0200
Re: Another OOP thread; everything on the stack is an object hughaguilar96@yahoo.com - 2013-05-16 18:31 -0700
Re: Another OOP thread; everything on the stack is an object Alex McDonald <blog@rivadpm.com> - 2013-05-17 05:38 -0700
Re: Another OOP thread; everything on the stack is an object Alex McDonald <blog@rivadpm.com> - 2013-05-17 05:39 -0700
Re: Another OOP thread; everything on the stack is an object Bernd Paysan <bernd.paysan@gmx.de> - 2013-05-19 00:09 +0200
Re: Another OOP thread; everything on the stack is an object Ian Osgood <iano@quirkster.com> - 2013-05-25 11:36 -0700
Re: Another OOP thread; everything on the stack is an object Paul Rubin <no.email@nospam.invalid> - 2013-05-25 13:10 -0700
Re: Another OOP thread; everything on the stack is an object Ron Aaron <rambamist@gmail.com> - 2013-05-17 08:04 +0300
Re: Another OOP thread; everything on the stack is an object Paul Rubin <no.email@nospam.invalid> - 2013-05-16 22:19 -0700
Re: Another OOP thread; everything on the stack is an object Ron Aaron <rambamist@gmail.com> - 2013-05-17 08:26 +0300
Re: Another OOP thread; everything on the stack is an object Paul Rubin <no.email@nospam.invalid> - 2013-05-16 22:43 -0700
Re: Another OOP thread; everything on the stack is an object Ron Aaron <rambamist@gmail.com> - 2013-05-17 09:25 +0300
Re: Another OOP thread; everything on the stack is an object Mark Wills <markrobertwills@yahoo.co.uk> - 2013-05-17 00:26 -0700
Re: Another OOP thread; everything on the stack is an object anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-05-17 13:25 +0000
Re: Another OOP thread; everything on the stack is an object Bernd Paysan <bernd.paysan@gmx.de> - 2013-05-19 00:34 +0200
Re: Another OOP thread; everything on the stack is an object visualforth@rocketmail.com - 2013-05-18 15:55 -0700
Re: Another OOP thread; everything on the stack is an object Bernd Paysan <bernd.paysan@gmx.de> - 2013-05-19 01:27 +0200
Re: Another OOP thread; everything on the stack is an object Coos Haak <chforth@hccnet.nl> - 2013-05-19 01:35 +0200
Re: Another OOP thread; everything on the stack is an object Mark Wills <markrobertwills@yahoo.co.uk> - 2013-05-17 00:29 -0700
Re: Another OOP thread; everything on the stack is an object hughaguilar96@yahoo.com - 2013-05-18 19:38 -0700
Re: Another OOP thread; everything on the stack is an object Alex McDonald <blog@rivadpm.com> - 2013-05-17 05:40 -0700
Re: Another OOP thread; everything on the stack is an object Ron Aaron <rambamist@gmail.com> - 2013-05-17 16:18 +0300
Re: Another OOP thread; everything on the stack is an object anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-05-17 12:50 +0000
Re: Another OOP thread; everything on the stack is an object Paul Rubin <no.email@nospam.invalid> - 2013-05-17 06:09 -0700
Re: Another OOP thread; everything on the stack is an object Ron Aaron <rambamist@gmail.com> - 2013-05-17 16:25 +0300
Re: Another OOP thread; everything on the stack is an object alberto@hal-pc.org (Alberto) - 2013-05-17 14:35 +0000
Re: Another OOP thread; everything on the stack is an object Steve <nospam275@gmail.com> - 2013-05-19 05:48 -0700
Re: Another OOP thread; everything on the stack is an object Jason Damisch <jasondamisch@yahoo.com> - 2013-05-25 19:56 -0700
csiph-web