-
Notifications
You must be signed in to change notification settings - Fork 15
Closed
Description
Is it possible to define parametric types with SimpleTraits.jl
?
The package documentation shows examples like
@traitfn f(x::X) where {X; IsNice{X}} = "Very nice!"
@traitfn f(x::X) where {X; !IsNice{X}} = "Not so nice!"
but I have yet to see the same for parametric types. What I'm looking for is something like
@traitstruct MyType{X} where {X; IsNice{X}} end
Does this syntax exist somewhere?
Metadata
Metadata
Assignees
Labels
No labels