Explorar o código

structuring plugin system

Nicolas Winkler %!s(int64=4) %!d(string=hai) anos
pai
achega
e4cfd473fa
Modificáronse 1 ficheiros con 3 adicións e 3 borrados
  1. 3 3
      libmandel/src/CalcPlugin.cpp

+ 3 - 3
libmandel/src/CalcPlugin.cpp

@@ -22,9 +22,9 @@ CalcPlugin::~CalcPlugin(void)
 
 const std::vector<mnd::MandelGenerator*>& CalcPlugin::getGenerators(void)
 {
-    static std::vector<mnd::MandelGenerator*> empty = {};
+    static const std::vector<mnd::MandelGenerator*> empty = {};
     if (!isValid()) {
-        return {};
+        return empty;
     }
 
     using GeneratorGetter =
@@ -35,6 +35,6 @@ const std::vector<mnd::MandelGenerator*>& CalcPlugin::getGenerators(void)
         return gg();
     }
     else {
-        return nullptr;
+        return empty;
     }
 }