diff --git a/include/dmlc/parameter.h b/include/dmlc/parameter.h index dd631c39f5..0830cb99cd 100644 --- a/include/dmlc/parameter.h +++ b/include/dmlc/parameter.h @@ -994,7 +994,7 @@ class FieldEntry : public FieldEntryNumeric, float> { os << "Invalid Parameter format for " << key_ << " expect " << type_ << " but value=\'" << value << '\''; throw dmlc::ParamError(os.str()); - } catch (const std::out_of_range) { + } catch (const std::out_of_range&) { std::ostringstream os; os << "Out of range value for " << key_ << ", value=\'" << value << '\''; throw dmlc::ParamError(os.str()); @@ -1019,7 +1019,7 @@ class FieldEntry os << "Invalid Parameter format for " << key_ << " expect " << type_ << " but value=\'" << value << '\''; throw dmlc::ParamError(os.str()); - } catch (const std::out_of_range) { + } catch (const std::out_of_range&) { std::ostringstream os; os << "Out of range value for " << key_ << ", value=\'" << value << '\''; throw dmlc::ParamError(os.str());