From 777afb8ee80772d3cde3d083042a96385713ca0c Mon Sep 17 00:00:00 2001 From: Jaakko Ruohio Date: Sun, 12 Jan 2025 20:33:05 +0200 Subject: [PATCH] Improve error message for not implemented geometric types --- src/geos_types.jl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/geos_types.jl b/src/geos_types.jl index 0d45a5e..e3b87f2 100644 --- a/src/geos_types.jl +++ b/src/geos_types.jl @@ -638,8 +638,9 @@ function geomFromGEOS( return MultiLineString(ptr, context) elseif id == GEOS_MULTIPOLYGON return MultiPolygon(ptr, context) - else - @assert id == GEOS_GEOMETRYCOLLECTION + elseif id == GEOS_GEOMETRYCOLLECTION return GeometryCollection(ptr, context) + else + throw(ErrorException("Geometric type with code $id not implemented.")) end end