• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

ranocha / SummationByPartsOperators.jl / 24343758299

13 Apr 2026 12:38PM UTC coverage: 93.086% (-0.1%) from 93.214%
24343758299

push

github

web-flow
require Julia 1.10; update SciMLBase, RecursiveArrayTools; switch to OrdinaryDiffEqSSPRK for tests (#406)

* require Julia 1.10; update SciMLBase, REcursiveArrayTools

* update CI

* add Downgrade CI workflow (#407)

* add Downgrade CI workflow

* update dependencies for Downgrade

* remove Requires.jl

* remove compat note

* fix Downgrade

* remove VERSION checks not needed anymore

* format

* fix Downgrade

* update StaticArrays.jl

* bump OrdinaryDiffEqSSPRK

* bump OrdinaryDiffEqSSPRK

* bump OrdinaryDiffEqSSPRK

* bump OrdinaryDiffEqSSPRK

* fix Downgrade

86 of 88 new or added lines in 1 file covered. (97.73%)

9 existing lines in 4 files now uncovered.

6328 of 6798 relevant lines covered (93.09%)

591177.81 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

95.24
/ext/SummationByPartsOperatorsStructArraysExt.jl
1
module SummationByPartsOperatorsStructArraysExt
2

3
if isdefined(Base, :get_extension)
4
    using StructArrays: StructArray, components
5
else
6
    using ..StructArrays: StructArray, components
7
end
8

9
using SummationByPartsOperators: AbstractDerivativeOperator
10
import SummationByPartsOperators: mul!
11

12
using InteractiveUtils: subtypes
13

14
function _subtypes(type::Type)
8✔
15
    out = Any[]
8✔
16
    _subtypes!(out, type)
8✔
17
end
18

19
function _subtypes!(out, type::Type)
240✔
20
    if !isabstracttype(type)
240✔
21
        push!(out, type)
176✔
22
    else
23
        foreach(T -> _subtypes!(out, T), subtypes(type))
296✔
24
    end
UNCOV
25
    out
×
26
end
27

28
# Use lispy tuple programming to iterate over all fields of a `StructArray`.
29
# Use ugly `@eval` to resolve ambiguities arising from existing `mul!` definitions.
30
for Dtype in _subtypes(AbstractDerivativeOperator)
31
    @eval Base.@propagate_inbounds function mul!(dest::StructArray, D::$Dtype,
48✔
32
                                                 u::StructArray)
33
        iterate_mul!(Tuple(components(dest)), D, Tuple(components(u)))
84✔
34
        return dest
84✔
35
    end
36

37
    @eval Base.@propagate_inbounds function mul!(dest::StructArray, D::$Dtype,
36✔
38
                                                 u::StructArray, α)
39
        iterate_mul!(Tuple(components(dest)), D, Tuple(components(u)), α)
36✔
40
        return dest
36✔
41
    end
42

43
    @eval Base.@propagate_inbounds function mul!(dest::StructArray, D::$Dtype,
36✔
44
                                                 u::StructArray, α, β)
45
        iterate_mul!(Tuple(components(dest)), D, Tuple(components(u)), α, β)
36✔
46
        return dest
36✔
47
    end
48
end
49

50
Base.@propagate_inbounds function iterate_mul!(dest::NTuple{N, Any},
252✔
51
                                               D::AbstractDerivativeOperator,
52
                                               u::NTuple{N, Any}, args...) where {N}
53
    mul!(first(dest), D, first(u), args...)
504✔
54
    iterate_mul!(Base.tail(dest), D, Base.tail(u), args...)
504✔
55
end
56

57
iterate_mul!(::Tuple{}, D::AbstractDerivativeOperator, ::Tuple{}, args...) = nothing
156✔
58

59
end # module
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc