Skip to content

Commit

Permalink
reduce ambiguities (#1072)
Browse files Browse the repository at this point in the history
  • Loading branch information
hyrodium committed Aug 9, 2022
1 parent d36a5ef commit 0feac14
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
3 changes: 3 additions & 0 deletions test/FieldMatrix.jl
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@
eval(quote
struct TupleField2 <: FieldMatrix{1, 1, NTuple{2, Int}}
x::NTuple{2, Int}
function TupleField2(x::NTuple{2,Int})
new(x)
end
end
end)

Expand Down
3 changes: 3 additions & 0 deletions test/FieldVector.jl
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,9 @@
eval(quote
struct TupleField <: FieldVector{1, NTuple{2, Int}}
x::NTuple{2, Int}
function TupleField(x::NTuple{2,Int})
new(x)
end
end
end)

Expand Down
4 changes: 2 additions & 2 deletions test/ambiguities.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Allow no new ambiguities (see #18), unless you fix some old ones first!

const allowable_ambiguities = VERSION v"1.7" ? 10 :
VERSION v"1.6" ? 11 : error("version must be ≥1.6")
const allowable_ambiguities = VERSION v"1.7" ? 0 :
VERSION v"1.6" ? 1 : error("version must be ≥1.6")

# TODO: Revisit and fix. See
# https://github.com/JuliaLang/julia/pull/36962
Expand Down

0 comments on commit 0feac14

Please sign in to comment.