Skip to content
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

Add array:unique langlib function #776

Open
jclark opened this issue Mar 12, 2021 · 0 comments
Open

Add array:unique langlib function #776

jclark opened this issue Mar 12, 2021 · 0 comments
Labels
Area/LangLib Relates to lang.* libraries Type/Improvement Enhancement to language design

Comments

@jclark
Copy link
Collaborator

jclark commented Mar 12, 2021

This is defined for anydata[], works like the Unix uniq command i.e. it creates a new array that omits any member that is == to an earlier member.

The input array would not be required to be sorted: the implementation would be expected to use a hash table to remove duplicates (or could create a temporary sorted array and use that).

Query will eventually be able to do this using grouping and aggregation (#441), but this is a lightweight, simple solution.

@jclark jclark added the Area/LangLib Relates to lang.* libraries label Mar 12, 2021
@jclark jclark added this to the Swan Lake polish milestone Mar 12, 2021
@jclark jclark modified the milestones: Nutcracker, Swan Lake updates Feb 15, 2022
@anupama-pathirage anupama-pathirage added the Type/Improvement Enhancement to language design label Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area/LangLib Relates to lang.* libraries Type/Improvement Enhancement to language design
Projects
None yet
Development

No branches or pull requests

2 participants