-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pointer::union
is misleadingly named
#28
Comments
Ugh, thank you. That one is especially embarrassing 🤦🏻♂️. I'll deprecate it and rename for 0.4. |
Awesome! I think you meant the rename for 0.5 though? We are at 0.4.x releases. |
I meant I’ll rename it but alias the existing, improperly named, fn to the
new and deprecate it.
…On Tue, Mar 19, 2024 at 6:52 PM André Mello ***@***.***> wrote:
Awesome! I think you meant the rename for 0.5 though? We are at 0.4.x
releases.
—
Reply to this email directly, view it on GitHub
<#28 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIGFZENJSYNNZ6U3CZUDV3YZC6ULAVCNFSM6AAAAABE6NR66OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMBYGI4TMOJTGM>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When used as an operator, the term
union
conventionally alludes to the set theoretical definition. From Wikipedia:In more concrete terms, when given two sets of items, their union is the set of all elements from either set. So when the term is applied to a JSON Pointer, one might expect that the result would somehow contain the tokens from both inputs, when in reality it only contains their shared part. This more accurately represents an intersection operation, which is the opposite of a union, so the naming is surprising and easily leads to confusion.
The most accurate term would be longest common prefix, as this is the algorithm that the method implements. To keep it short, the abbreviation
lcp
is often used. I thinkintersection
would probably also be fine, though.The text was updated successfully, but these errors were encountered: