#include "Fractal.h"
#include <hayai/hayai.hpp>
+#include "Exception.h"
using namespace Fractal;
virtual void SetUp() {
FractalCommon::load_base();
impl = FractalCommon::registry.get("Mandelbrot");
- if (impl==0) throw "Cannot find my fractal!";
+ if (impl==0) THROW(BrotFatalException, "Cannot find my fractal!");
/* A point (found by experiment) that's in the set but not
* in the special-case cut-off regions */
#define FRACTAL_INTERNALS_H_
#include "FractalMaths.h"
+#include "Exception.h"
namespace Fractal {
switch(type) {
ALL_MATHS_TYPES(DO_PLOT)
case Maths::MathsType::MAX:
- throw "Unhandled value type";
+ THROW(BrotFatalException, "Unhandled maths type!");
}
}
};
#include <vector>
#include <glib.h>
#include "Fractal.h"
+#include "Exception.h"
#include "Fractal-internals.h"
using namespace Fractal;
if (it->val == t)
return it->name;
}
- throw "Unhandled maths type!";
+ THROW(BrotFatalException, "Unhandled maths type!");
}
Value Maths::min_pixel_size(MathsType t) {
if (it->val == t)
return it->min_pixel_size;
}
- throw "Unhandled maths type!";
+ THROW(BrotFatalException, "Unhandled maths type!");
}
Value Maths::smallest_min_pixel_size() {
#include <gtest/gtest.h>
#include "Fractal.h"
+#include "Exception.h"
using namespace Fractal;
virtual void SetUp() {
FractalCommon::load_base();
impl = FractalCommon::registry.get("Mandelbrot");
- if (impl==0) throw "Cannot find my fractal!";
+ if (impl==0) THROW(BrotFatalException,"Cannot find my fractal!");
}
virtual void TearDown() {
FractalCommon::unload_registry();