Skip to content

Commit 14043c4

Browse files
committed
bugfix
1 parent 52fe69f commit 14043c4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/primitives.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ that returns `true`.
1515
function isprimtype end
1616

1717
@traitdef IsPrimType{X}
18-
@traitdef IsPrimType{X} <- isprimtype(X)
18+
@traitimpl IsPrimType{X} <- isprimtype(X)
1919
isprimtype(X) = false # default
2020

2121
export basemeasure
@@ -30,7 +30,7 @@ For measures not defined in this way, we'll typically have `basemeasure(μ) ==
3030
"""
3131
function basemeasure end
3232

33-
basemeasure::M) where {IsPrimType{M}} = μ
33+
@traitfn basemeasure::M) where {M; IsPrimType{M}} = μ
3434

3535
include("primitives/trivial.jl")
3636
include("primitives/lebesgue.jl")
@@ -43,4 +43,4 @@ include("primitives/dirac.jl")
4343
isreptype(X) = false # set default
4444

4545
# Every primitive measure is also a representative
46-
isreptype::M) where {IsPrimType{M}} = true
46+
@traitfn isreptype::M) where {M; IsPrimType{M}} = true

0 commit comments

Comments
 (0)