From e09745448001f2387ca76c0abf3232aad53df4c5 Mon Sep 17 00:00:00 2001 From: Wilf Wilson Date: Wed, 17 Feb 2021 11:55:49 +0000 Subject: [PATCH] init: only define GRAPE variables when undefined --- init.g | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/init.g b/init.g index 9dc3d6002..3c1a07d77 100644 --- a/init.g +++ b/init.g @@ -27,9 +27,14 @@ fi; BindGlobal("DIGRAPHS_IsGrapeLoaded", IsPackageMarkedForLoading("grape", "4.8.1")); -if not DIGRAPHS_IsGrapeLoaded then +# To avoid warnings when GRAPE is not loaded +if not IsBound(IsGraph) then IsGraph := ReturnFalse; +fi; +if not IsBound(Vertices) then Vertices := IdFunc; +fi; +if not IsBound(Adjacency) then Adjacency := IdFunc; fi;