Skip to content

Commit 651600e

Browse files
Revert setdiff change as there is no measurable gain
1 parent 2b3ff9c commit 651600e

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/Dofs/ConstraintHandler.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ prescribed_dofs(ch::ConstraintHandler) = ch.prescribed_dofs
261261

262262
# Equivalent to `copy!(out, setdiff(1:n_entries, diff))`, but requires that
263263
# `issorted(diff)` and that `1 ≤ diff[1] ≤ diff[end] ≤ n_entries`
264-
function _sorted_setdiff!(out::Vector{Ti}, n_entries::Ti, diff::Vector{Ti}) where {Ti}
264+
function _sorted_setdiff!(out::Vector{Ti}, n_entries::Integer, diff::Vector{Ti}) where {Ti}
265265
n_diff = length(diff)
266266
resize!(out, n_entries - n_diff)
267267
diff_ind = out_ind = 1
@@ -291,7 +291,7 @@ function close!(ch::ConstraintHandler{<:Any, <:Any, Ti}) where {Ti}
291291
ch.affine_inhomogeneities .= ch.affine_inhomogeneities[I]
292292
ch.dofcoefficients .= ch.dofcoefficients[I]
293293

294-
_sorted_setdiff!(ch.free_dofs, Ti(ndofs(ch.dh)), ch.prescribed_dofs)
294+
_sorted_setdiff!(ch.free_dofs, ndofs(ch.dh), ch.prescribed_dofs)
295295

296296
for i in 1:length(ch.prescribed_dofs)
297297
ch.dofmapping[ch.prescribed_dofs[i]] = i
@@ -1253,7 +1253,7 @@ function _add!(
12531253
@assert rotation_matrix !== nothing
12541254
for (i, ki) in pairs(k)
12551255
# u_mirror = R ⋅ u_image
1256-
vs = Pair{Int, eltype(Tv)}[v[j] => rotation_matrix[i, j] for j in 1:length(v)]
1256+
vs = Pair{Int, Tv}[v[j] => rotation_matrix[i, j] for j in 1:length(v)]
12571257
ac = AffineConstraint(ki, vs, zero(Tv))
12581258
add!(ch, ac)
12591259
end

0 commit comments

Comments
 (0)