Re: [PATCH] Add CANONICAL option to xmlserialize

From: Chapman Flack <chap(at)anastigmatix(dot)net>
To: Jim Jones <jim(dot)jones(at)uni-muenster(dot)de>
Cc: vignesh C <vignesh21(at)gmail(dot)com>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: [PATCH] Add CANONICAL option to xmlserialize
Date: 2023-10-04 21:05:37
Message-ID: 964fab10c64f8aadc765b53ae2cf2782@anastigmatix.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2023-10-04 12:19, Jim Jones wrote:
> On 04.10.23 11:39, vignesh C wrote:
>> 1) Why the default option was chosen without comments shouldn't it be
>> the other way round?
> I'm not sure it is the way to go. The main idea is to check if two
> documents have the same content, and comments might be different even
> if the contents of two documents are identical. What are your concerns
> regarding this default behaviour?

I hope I'm not butting in, but I too would be leery of any default
behavior that's going to say thing1 and thing2 are the same thing
but ignoring (name part of thing here). If that's the comparison
I mean to make, and it's as easy as CANONICAL WITHOUT COMMENTS
to say that's what I mean, I'd be happy to write that. It also means
that the next person reading my code will know "oh, he means
'same' in *that* way", without having to think about it.

Regards,
-Chap

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Nico Williams 2023-10-04 21:15:06 Re: Pre-proposal: unicode normalized text
Previous Message James Coleman 2023-10-04 21:01:14 Re: Opportunistically pruning page before update