New repo in kdereview: kalk

Thomas Baumgart thb at net-bembel.de
Tue May 4 18:19:27 BST 2021


On Dienstag, 4. Mai 2021 19:00:13 CEST hanyoung wrote:

> Flex doesn't take care of separators, MPFR and GMP do. Flex is merely scanning for numbers and operators to pass to Bison.

That's true. For lexical analysis this does not really matter. How about a space as thousand delimiter?

    Swedish locale: 1 000,00

Doesn't this may trick you lexer? Sorry, you asked for more of those separators/delimiters. But I think those three are the most common.

Cheers

Thomas


> Sent with ProtonMail Secure Email.
> 
> ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> On Wednesday, May 5, 2021 12:56 AM, Thomas Baumgart <thb at net-bembel.de> wrote:
> 
> > Han,
> >
> > On Dienstag, 4. Mai 2021 11:36:04 CEST hanyoung wrote:
> >
> > > Pushed an inelegant solution - include "," as decimal separator in flex. As long as there aren't any more decimal separator we're cool.
> >
> > Not sure if this appropriate, but I wanted to warn you about the dilemma that in some locale the thousand separator and the decimal symbol are exactly the opposite. Example:
> >
> > German locale: 1.000,00 -> one thousand
> > US locale : 1,000.00 -> one thousand
> >
> > So simply treating the comma and the dot alike without taking the locale into account may result in wrong values.
> >
> > Cheers,
> >
> > Thomas
> >
> > > ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> > > On Tuesday, May 4, 2021 6:54 AM, Albert Astals Cid aacid at kde.org wrote:
> > >
> > > > Added a failing test athttps://invent.kde.org/plasma-mobile/kalk/-/merge_requests/22
> > > > Now you have to make it work :)
> > > > Cheers,
> > > > Albert
> >
> > --
> >
> > Regards
> >
> > Thomas Baumgart
> >
> > https://www.signal.org/ Signal, the better WhatsApp
> >
> > --------------------------------------------------------------------------------
> >
> > Of all the computing resources available, the most valuable one is
> > programmers' time. Especially in open source where most of us have to
> > sneak in time to write and debug code. (Ace Jones)
> >
> > --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
> 
> 
> 

-- 

Regards

Thomas Baumgart

https://www.signal.org/       Signal, the better WhatsApp
-------------------------------------------------------------
Good judgment comes from experience,
experience comes from bad judgment -- Chuck Hackett
-------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 868 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20210504/db310e71/attachment.sig>


More information about the kde-core-devel mailing list