Skip to content

Commit

Permalink
Run JuliaFormatter
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
mhauru and github-actions[bot] authored Oct 16, 2024
1 parent 06fbe70 commit a02ec4c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/varinfo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ function subset(varinfo::TypedVarInfo, vns::AbstractVector{<:VarName})
)
end

function subset(metadata::Metadata, vns_given::AbstractVector{VN}) where VN<:VarName
function subset(metadata::Metadata, vns_given::AbstractVector{VN}) where {VN<:VarName}
# TODO: Should we error if `vns` contains a variable that is not in `metadata`?
# For each `vn` in `vns`, get the variables subsumed by `vn`.
vns = mapreduce(vcat, vns_given; init=VN[]) do vn
Expand Down
3 changes: 2 additions & 1 deletion test/varinfo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,8 @@ DynamicPPL.getspace(::DynamicPPL.Sampler{MySAlg}) = (:s,)
vns_supported_standard
end

@testset ("$(convert(Vector{VarName}, vns_subset)) empty") for vns_subset in vns_supported
@testset ("$(convert(Vector{VarName}, vns_subset)) empty") for vns_subset in
vns_supported
varinfo_subset = subset(varinfo, VarName[])
@test isempty(varinfo_subset)
end
Expand Down

0 comments on commit a02ec4c

Please sign in to comment.