Skip to content

Define a Subset of a Scala 3 Enumeration #237

Closed Answered by pme123
pme123 asked this question in Q&A
Discussion options

You must be logged in to vote

Ah, thanks. .type did the trick: type ContractProduct = DocId :| any.StrictEqual[DocId.ContractB.type]

For only one you have right, this would be working: type ContractProduct = DocId.ContractB.type. But this was only a simplified example. In reality I need a subset, like: DocId :| any.In[(DocId.ContractB.type, DocId.ContractC.type)] which now also works!

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@Iltotore
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by pme123
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants