Re: [PATCH] Implement uuid_version() - Mailing list pgsql-hackers

From Fabien COELHO
Subject Re: [PATCH] Implement uuid_version()
Date
Msg-id alpine.DEB.2.21.1907131702230.22273@lancre
Whole thread Raw
In response to Re: [PATCH] Implement uuid_version()  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Responses Re: [PATCH] Implement uuid_version()  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
List pgsql-hackers
Hello Peter,

>> About doc: I'd consider "generation" instead of "generating" as a
>> secondary index term.
>
> We do use the "-ing" form for other secondary index terms.  It's useful
> because the concatenation of primary and secondary term should usually
> make a phrase of some sort.  The alternative would be "generation of",
> but that doesn't seem clearly better.

Ok, fine. I looked but did not find other instances of "generating".

>> What about avoiding a redirection with something like:
>>
>> Datum (* const pg_random_uuid)(PG_FUNCTION_ARGS) = gen_random_uuid;
>
> That seems very confusing.

Dunno. Possibly. The user does not have to look at the implementation, and 
probably such code would deserve a comment.

The point is to avoid one call so as to perform the same (otherwise the 
pg_random_uuid would be slightly slower), and to ensure that it behaves 
the same, as it would be the very same function by construction.

I've switched the patch to ready anyway.

-- 
Fabien.



pgsql-hackers by date:

Previous
From: Joe Conway
Date:
Subject: Re: [Proposal] Table-level Transparent Data Encryption (TDE) and KeyManagement Service (KMS)
Next
From: Tom Lane
Date:
Subject: Re: Check-out mutable functions in check constraints