Skip to content

Commit

Permalink
Merge pull request #60 from j-fu/disallow_mod_dot_x
Browse files Browse the repository at this point in the history
Don't set gmsh.model
  • Loading branch information
j-fu authored Sep 27, 2024
2 parents 41c41df + 84af819 commit c9144ca
Showing 1 changed file with 3 additions and 16 deletions.
19 changes: 3 additions & 16 deletions ext/ExtendableGridsGmshExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -172,14 +172,7 @@ This function initalizes and finalized gmsh.
function simplexgrid_to_gmshfile(grid::ExtendableGrid; filename::String = "")
gmsh.initialize()

if VERSION >= v"1.9"
# This possibility is new in 1.9, see
# https://github.com/JuliaLang/julia/blob/release-1.9/NEWS.md#new-language-features
gmsh.model = simplexgrid_to_mod(grid)
mod = gmsh.model
else
mod = simplexgrid_to_mod(grid)
end
mod = simplexgrid_to_mod(grid)

if filename != ""
gmsh.write(filename)
Expand All @@ -200,14 +193,8 @@ This function initializes and finalized gmsh.
"""
function mixedgrid_to_gmshfile(grid::ExtendableGrid; filename::String = "")
gmsh.initialize()
if VERSION >= v"1.9"
# This possibility is new in 1.9, see
# https://github.com/JuliaLang/julia/blob/release-1.9/NEWS.md#new-language-features
gmsh.model = mixedgrid_to_mod(grid)
mod = gmsh.model
else
mod = mixedgrid_to_mod(grid)
end

mod = mixedgrid_to_mod(grid)

if filename != ""
gmsh.write(filename)
Expand Down

0 comments on commit c9144ca

Please sign in to comment.