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


Groups > comp.arch.embedded > #23463

Re: Decimal Point vs. Decimal Comma

From Bernd Paysan <bernd.paysan@gmx.de>
Newsgroups comp.arch.embedded, comp.lang.forth
Subject Re: Decimal Point vs. Decimal Comma
Date 2016-04-03 23:14 +0000
Organization A noiseless patient Spider
Message-ID <nds85b$9os$1@dont-email.me> (permalink)
References <ndpeif$7og$1@dont-email.me> <2016Apr3.082356@mips.complang.tuwien.ac.at>

Cross-posted to 2 groups.

Show all headers | View raw


Am Sun, 03 Apr 2016 06:23:56 +0000 schrieb Anton Ertl:

> A very early version of Gforth also worked that way, but I removed this
> feature, because it's more important to be able to get a useful error
> message if you use "2,", but the Forth system does not define it.  I
> have not missed this feature, and I come from the part of the world that
> uses decimal comma.

VFX has dp-char and fp-char to store the currently used decimal separator 
for doubles and floats (actually, a zero-terminated string of a few 
characters), by default, dp-char is both '.' and ',', so you can enter 
both forms:

 VFX Forth for Linux IA32

123,456 d. 123456  ok
123.456 d. 123456  ok

fp-char is by default just '.'.

Gforth's current development versions also have dp-char and fp-char, but 
only one possible character; default is ".".  This allows to change the 
character in case you want to read localized numbers.

-- 
Bernd Paysan
"If you want it done right, you have to do it yourself"
net2o ID: kQusJzA;7*?t=uy@X}1GWr!+0qqp_Cn176t4(dQ*
http://bernd-paysan.de/

Back to comp.arch.embedded | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Decimal Point vs. Decimal Comma rickman <gnuarm@gmail.com> - 2016-04-02 17:49 -0400
  Re: Decimal Point vs. Decimal Comma anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-04-03 06:23 +0000
    Re: Decimal Point vs. Decimal Comma rickman <gnuarm@gmail.com> - 2016-04-03 02:59 -0400
    Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-03 23:14 +0000
      Re: Decimal Point vs. Decimal Comma Ron Aaron <rambamist@gmail.com> - 2016-04-04 07:18 +0300
        Re: Decimal Point vs. Decimal Comma Ron Aaron <rambamist@gmail.com> - 2016-04-04 07:48 +0300
  Re: Decimal Point vs. Decimal Comma upsidedown@downunder.com - 2016-04-03 09:45 +0300
  Re: Decimal Point vs. Decimal Comma Nils M Holm <nmh@ananda.local> - 2016-04-03 07:32 +0000
  Re: Decimal Point vs. Decimal Comma George Neuner <gneuner2@comcast.net> - 2016-04-03 05:25 -0400
    Re: Decimal Point vs. Decimal Comma Robert Wessel <robertwessel2@yahoo.com> - 2016-04-03 17:22 -0500
  Re: Decimal Point vs. Decimal Comma Norbert_Paul <norbertpauls_spambin@yahoo.com> - 2016-04-03 14:05 +0200
  Re: Decimal Point vs. Decimal Comma Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2016-04-03 14:18 +0200
    Re: Decimal Point vs. Decimal Comma upsidedown@downunder.com - 2016-04-03 20:24 +0300
      Re: Decimal Point vs. Decimal Comma Niklas Holsti <niklas.holsti@tidorum.invalid> - 2016-04-03 21:05 +0300
        Re: Decimal Point vs. Decimal Comma Albert van der Horst <albert@spenarnc.xs4all.nl> - 2016-04-04 09:00 +0000
      Re: Decimal Point vs. Decimal Comma Ron Aaron <rambamist@gmail.com> - 2016-04-03 21:16 +0300
        Re: Decimal Point vs. Decimal Comma Albert van der Horst <albert@spenarnc.xs4all.nl> - 2016-04-04 09:17 +0000
          Re: Decimal Point vs. Decimal Comma Ron Aaron <rambamist@gmail.com> - 2016-04-04 12:46 +0300
            Re: Decimal Point vs. Decimal Comma anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-04-05 06:02 +0000
      Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-03 23:21 +0000
        Re: Decimal Point vs. Decimal Comma anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-04-04 07:11 +0000
          Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-04 21:11 +0000
      Re: Decimal Point vs. Decimal Comma Robert Wessel <robertwessel2@yahoo.com> - 2016-04-04 00:13 -0500
        Re: Decimal Point vs. Decimal Comma "Boudewijn Dijkstra" <sp4mtr4p.boudewijn@indes.com> - 2016-04-04 14:06 +0200
      Re: Decimal Point vs. Decimal Comma Nobody <nobody@nowhere.invalid> - 2016-04-05 03:32 +0100
        Re: Decimal Point vs. Decimal Comma upsidedown@downunder.com - 2016-04-05 09:56 +0300
          Re: Decimal Point vs. Decimal Comma Albert van der Horst <albert@spenarnc.xs4all.nl> - 2016-04-05 10:03 +0000
            Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-05 21:42 +0000
          Re: Decimal Point vs. Decimal Comma George Neuner <gneuner2@comcast.net> - 2016-04-05 11:11 -0400
            Re: Decimal Point vs. Decimal Comma Andrew Haley <andrew29@littlepinkcloud.invalid> - 2016-04-05 11:33 -0500
            Re: Decimal Point vs. Decimal Comma anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-04-06 12:50 +0000
        Re: Decimal Point vs. Decimal Comma anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-04-05 07:15 +0000
          Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-05 21:50 +0000
            Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-06 01:18 +0300
              Re: Decimal Point vs. Decimal Comma Charles Allen <ccallen@iceland.freeshell.org> - 2016-04-06 15:20 +0000
                Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-06 18:58 +0300
                Re: Decimal Point vs. Decimal Comma Ed Prochak <edprochak@gmail.com> - 2016-04-07 07:04 -0700
                Re: Decimal Point vs. Decimal Comma Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2016-04-07 23:40 +0200
                Re: Decimal Point vs. Decimal Comma lasselangwadtchristensen@gmail.com - 2016-04-07 16:04 -0700
                Re: Decimal Point vs. Decimal Comma David Brown <david.brown@hesbynett.no> - 2016-04-08 09:50 +0200
                Re: Decimal Point vs. Decimal Comma rickman <gnuarm@gmail.com> - 2016-04-09 01:01 -0400
                Re: Decimal Point vs. Decimal Comma David Brown <david.brown@hesbynett.no> - 2016-04-09 13:48 +0200
                Re: Decimal Point vs. Decimal Comma mac <acolvin@efunct.com> - 2016-04-11 18:52 +0000
              Re: Decimal Point vs. Decimal Comma Bernd Paysan <bernd.paysan@gmx.de> - 2016-04-08 23:11 +0000
                Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-09 03:19 +0300
                Re: Decimal Point vs. Decimal Comma Ed Prochak <edprochak@gmail.com> - 2016-04-09 15:04 -0700
                Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-10 01:49 +0300
                Re: Decimal Point vs. Decimal Comma Ed Prochak <edprochak@gmail.com> - 2016-04-12 11:48 -0700
                Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-12 22:53 +0300
                Re: Decimal Point vs. Decimal Comma Paul <paul@pcserviceselectronics.co.uk> - 2016-04-12 23:03 +0100
                Re: Decimal Point vs. Decimal Comma David Brown <david.brown@hesbynett.no> - 2016-04-13 09:21 +0200
                Re: Decimal Point vs. Decimal Comma Paul <paul@pcserviceselectronics.co.uk> - 2016-04-13 16:51 +0100
                Re: Decimal Point vs. Decimal Comma mac <acolvin@efunct.com> - 2016-04-11 18:52 +0000
                Re: Decimal Point vs. Decimal Comma Dimiter_Popoff <dp@tgi-sci.com> - 2016-04-11 23:39 +0300
      Re: Decimal Point vs. Decimal Comma Ed Prochak <edprochak@gmail.com> - 2016-04-07 06:39 -0700

csiph-web