diff src/SbpOperators/boundaryops/boundary_restriction.jl @ 989:7bf3121c6864 feature/stencil_set_type

Add type StencilSet
author Vidar Stiernström <vidar.stiernstrom@it.uu.se>
date Thu, 17 Mar 2022 21:31:20 +0100
parents 365bc4e2a6a2
children 99d1f5651d0b
line wrap: on
line diff
--- a/src/SbpOperators/boundaryops/boundary_restriction.jl	Wed Mar 16 18:39:00 2022 +0100
+++ b/src/SbpOperators/boundaryops/boundary_restriction.jl	Thu Mar 17 21:31:20 2022 +0100
@@ -13,7 +13,7 @@
 
 See also: [`boundary_operator`](@ref).
 """
-function boundary_restriction(grid, closure_stencil::Stencil, boundary)
+function boundary_restriction(grid, closure_stencil, boundary)
     converted_stencil = convert(Stencil{eltype(grid)}, closure_stencil)
     return SbpOperators.boundary_operator(grid, converted_stencil, boundary)
 end
@@ -21,7 +21,6 @@
 """
     boundary_restriction(grid, stencil_set, boundary)
 
-Creates a `boundary_restriction` operator on `grid` given a parsed TOML
-`stencil_set`.
+Creates a `boundary_restriction` operator on `grid` given a `stencil_set`.
 """
-boundary_restriction(grid, stencil_set, boundary) = boundary_restriction(grid, parse_stencil(stencil_set["e"]["closure"]), boundary)
+boundary_restriction(grid, stencil_set::StencilSet, boundary) = boundary_restriction(grid, parse_stencil(stencil_set["e"]["closure"]), boundary)