hofstadter-io / cuetils

CLI and library for diff, patch, and ETL operations on CUE, JSON, and Yaml
BSD 3-Clause "New" or "Revised" License
78 stars 6 forks source link

Set operators #19

Open verdverm opened 2 years ago

verdverm commented 2 years ago

Set operators on structs could be useful.

Extending them to lists could prove difficult, particularly lists of structs (which are difficult for all operations). Lists of basics could be done with a package (Go generics helpful here?).

(taken from https://github.com/cue-lang/cue/issues/454)

verdverm commented 2 years ago

union & intersection seem to have overlap with insert/upsert & pick respectively

maybe super/subset could be called contains/containedby?