Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #20016

Re: Double integer input

From anton@mips.complang.tuwien.ac.at (Anton Ertl)
Newsgroups comp.lang.forth
Subject Re: Double integer input
Date 2013-02-25 15:25 +0000
Organization Institut fuer Computersprachen, Technische Universitaet Wien
Message-ID <2013Feb25.162531@mips.complang.tuwien.ac.at> (permalink)
References (3 earlier) <kg6fbr$9m5$1@online.de> <2013Feb22.163514@mips.complang.tuwien.ac.at> <H-qdnbjG_ZCNX7rMnZ2dnUVZ_sidnZ2d@supernews.com> <2013Feb23.171502@mips.complang.tuwien.ac.at> <5128fc79.914962618@192.168.0.50>

Show all headers | View raw


stephenXXX@mpeforth.com (Stephen Pelc) writes:
>On Sat, 23 Feb 2013 16:15:02 GMT, anton@mips.complang.tuwien.ac.at
>(Anton Ertl) wrote:
>
>>However, I believe that having "," in numbers was a mistake.
...
>The idea that Forth is cast in stone by standards is not a good one.

Nobody proposed that idea, so why do you beat on it?

>We are in danger of making the number input words useless for
>application input.

Number input words were also not being discussed.

But now that you mention it: For floats the standard has a more
liberal syntax for >FLOAT, and a stricter syntax for the text
interpreter.  That's a good idea, as discussed not too long ago.  By
contrast, >NUMBER (as standardized) only processes digits, whereas a
double in the text interpreter also contains a ".".  Maybe it would be
good if there was common practice for something higher level (and more
liberal) than >NUMBER.

>It is just a fact that the use of ',' and '.'
>varies across several European regions without considering the rest
>of the world.

I live in one of thse regions where decimal mark is ",".  That does
not mean that numbers in Forth source code should be written that way.
In my part of the world we also say "wenn" where the English say "if",
but that does not mean that Forth should be extended to accept WENN,
SI, etc. in addition to IF.

If we want to support more flexible text interpreter number input
(including having a way to support "," as decimal mark) for the
scenario where the end user uses the text interpreter (with
application words on top of Forth), I think that there should be a way
to extend the number input.  Your DP-CHAR is one way, recongizers are
a more flexible way; in both cases I am not (yet?) convinced that this
feature works well with combining independently developed libraries
(the recognizer stack probably helps, but will users use it
appropriately).

- 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 | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Double integer input Rosangela Medeiros da Silva <rosangelamesil@gmail.com> - 2013-02-13 18:15 -0800
  Re: Double integer input Rosangela Medeiros da Silva <rosangelamesil@gmail.com> - 2013-02-14 02:07 -0800
    Re: Double integer input Coos Haak <chforth@hccnet.nl> - 2013-02-14 16:18 +0100
      Re: Double integer input Coos Haak <chforth@hccnet.nl> - 2013-02-14 16:27 +0100
      Re: Double integer input "A. K." <akk@nospam.org> - 2013-02-14 20:54 +0100
        Re: Double integer input Coos Haak <chforth@hccnet.nl> - 2013-02-14 23:20 +0100
  Re: Double integer input "Ed" <invalid@nospam.com> - 2013-02-22 11:00 +1100
    Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-21 14:24 -1000
      Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-22 01:50 +0100
        Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-22 15:35 +0000
          Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-22 18:15 +0100
            Re: Double integer input stephenXXX@mpeforth.com (Stephen Pelc) - 2013-02-22 19:02 +0000
            Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-23 17:27 +0000
              Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-24 03:42 +0100
          Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-22 09:08 -1000
            Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-23 16:15 +0000
              Re: Double integer input stephenXXX@mpeforth.com (Stephen Pelc) - 2013-02-23 17:35 +0000
                Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-25 15:25 +0000
              Re: Double integer input albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-02-23 19:34 +0000
                Re: Double integer input "Rod Pemberton" <do_not_have@notemailnotz.cnm> - 2013-02-23 18:35 -0500
              Re: Double integer input Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-02-23 14:58 -0600
                Re: Double integer input Zbiggy <zbigniew2011REMOVE@gmail.REMOVE.com> - 2013-02-23 22:01 +0100
                Re: Double integer input albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-02-24 04:03 +0000
                Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-23 18:13 -1000
                Re: Double integer input Zbiggy <zbigniew2011REMOVE@gmail.REMOVE.com> - 2013-02-24 12:01 +0100
                Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-25 18:09 +0000
                Re: Double integer input rickman <gnuarm@gmail.com> - 2013-02-24 15:01 -0500
                Re: Double integer input Coos Haak <chforth@hccnet.nl> - 2013-02-25 01:13 +0100
                Re: Double integer input Mark Wills <markrobertwills@yahoo.co.uk> - 2013-02-24 23:44 -0800
                Re: Double integer input rickman <gnuarm@gmail.com> - 2013-02-27 07:47 -0500
                Re: Double integer input Mark Wills <markrobertwills@yahoo.co.uk> - 2013-02-24 23:42 -0800
                Re: Double integer input Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-02-25 03:57 -0600
                Re: Double integer input albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-02-25 14:09 +0000
                Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-25 16:45 +0100
                Re: Double integer input Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-02-25 18:26 -0600
                Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-26 02:04 +0100
                Re: Double integer input Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-02-26 05:10 -0600
                Re: Double integer input Bernd Paysan <bernd.paysan@gmx.de> - 2013-02-26 15:31 +0100
                Re: Double integer input Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-02-26 10:28 -0600
                Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-25 16:38 +0000
              Re: Double integer input rickman <gnuarm@gmail.com> - 2013-02-24 14:54 -0500
                Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-24 11:59 -1000
                Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-02-25 18:11 +0000
                Re: Double integer input rickman <gnuarm@gmail.com> - 2013-02-27 07:58 -0500
                Re: Double integer input anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-03-02 17:10 +0000
      Re: Double integer input "Ed" <invalid@nospam.com> - 2013-02-22 13:22 +1100
        Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-21 16:31 -1000
      Re: Double integer input Alex McDonald <blog@rivadpm.com> - 2013-02-22 04:54 -0800
        Re: Double integer input "WJ" <w_a_x_man@yahoo.com> - 2013-02-24 22:05 +0000
          Re: Double integer input Paul Rubin <no.email@nospam.invalid> - 2013-02-24 15:02 -0800
          Re: Double integer input Brad Eckert <hwfwguy@gmail.com> - 2013-02-25 09:22 -0800
            Re: Double integer input Brad Eckert <hwfwguy@gmail.com> - 2013-02-25 10:21 -0800
          Re: Double integer input Alex McDonald <blog@rivadpm.com> - 2013-02-26 07:47 -0800
        Re: Double integer input "WJ" <w_a_x_man@yahoo.com> - 2013-02-28 06:27 +0000
      Re: Double integer input Paul Rubin <no.email@nospam.invalid> - 2013-02-23 21:34 -0800
        Re: Double integer input "Elizabeth D. Rather" <erather@forth.com> - 2013-02-24 08:16 -1000

csiph-web