Re: Non-decimal integer literals - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: Non-decimal integer literals
Date
Msg-id 97aa22d7-b80f-efa1-f368-3dbf73a15980@enterprisedb.com
Whole thread Raw
In response to Re: Non-decimal integer literals  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Non-decimal integer literals
List pgsql-hackers
On 26.01.22 01:02, Tom Lane wrote:
> Robert Haas <robertmhaas@gmail.com> writes:
>> On Tue, Jan 25, 2022 at 5:34 AM Peter Eisentraut
>> <peter.eisentraut@enterprisedb.com> wrote:
>>> Which part exactly?  There are several different changes proposed here.
> 
>> I was just going based on the description of the feature in your
>> original post. If someone is hoping that int4in() will accept only
>> ^\d+$ then they will be disappointed by this patch.
> 
> Maybe I misunderstood, but I thought this was about what you could
> write as a SQL literal, not about the I/O behavior of the integer
> types.  I'd be -0.1 on changing the latter.

I think it would be strange if I/O routines would accept a different 
syntax from the literals.  Also, the behavior of a cast from string/text 
to a numeric type is usually defined in terms of what the literal syntax 
is, so they need to be aligned.



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: JSONB docs patch
Next
From: Mark Dilger
Date:
Subject: Re: Granting SET and ALTER SYSTE privileges for GUCs