throw std::invalid_argument instead of std::exception

This commit is contained in:
bubnikv 2017-10-27 21:28:39 +02:00
parent 2455aee97c
commit 21633bc0ba

View File

@ -215,7 +215,11 @@ _constant()
bool has_infinite_skirt(); bool has_infinite_skirt();
bool has_skirt(); bool has_skirt();
std::vector<unsigned int> extruders() const; std::vector<unsigned int> extruders() const;
void validate() %code%{ std::string err = THIS->validate(); if (! err.empty()) throw std::exception(err.c_str()); %}; void validate() %code%{
std::string err = THIS->validate();
if (! err.empty())
throw std::invalid_argument(err.c_str());
%};
Clone<BoundingBox> bounding_box(); Clone<BoundingBox> bounding_box();
Clone<BoundingBox> total_bounding_box(); Clone<BoundingBox> total_bounding_box();
double skirt_first_layer_height(); double skirt_first_layer_height();