improve error messages
This commit is contained in:
@ -308,7 +308,7 @@ void Update::set_units(const char *style)
|
|||||||
neighbor->skin = 0.1;
|
neighbor->skin = 0.1;
|
||||||
|
|
||||||
} else
|
} else
|
||||||
error->all(FLERR, "Illegal units command");
|
error->all(FLERR, "Unknown units style {}", style);
|
||||||
|
|
||||||
delete[] unit_style;
|
delete[] unit_style;
|
||||||
unit_style = utils::strdup(style);
|
unit_style = utils::strdup(style);
|
||||||
@ -325,7 +325,7 @@ void Update::set_units(const char *style)
|
|||||||
|
|
||||||
void Update::create_integrate(int narg, char **arg, int trysuffix)
|
void Update::create_integrate(int narg, char **arg, int trysuffix)
|
||||||
{
|
{
|
||||||
if (narg < 1) error->all(FLERR, "Illegal run_style command");
|
if (narg < 1) utils::missing_cmd_args(FLERR, "run_style", error);
|
||||||
|
|
||||||
delete[] integrate_style;
|
delete[] integrate_style;
|
||||||
delete integrate;
|
delete integrate;
|
||||||
@ -390,14 +390,14 @@ void Update::new_integrate(char *style, int narg, char **arg, int trysuffix, int
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
error->all(FLERR, "Illegal integrate style");
|
error->all(FLERR, "Unknown integrate style {}", style);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
void Update::create_minimize(int narg, char **arg, int trysuffix)
|
void Update::create_minimize(int narg, char **arg, int trysuffix)
|
||||||
{
|
{
|
||||||
if (narg < 1) error->all(FLERR, "Illegal minimize_style command");
|
if (narg < 1) utils::missing_cmd_args(FLERR, "minimize_style", error);
|
||||||
|
|
||||||
delete[] minimize_style;
|
delete[] minimize_style;
|
||||||
delete minimize;
|
delete minimize;
|
||||||
@ -457,7 +457,7 @@ void Update::new_minimize(char *style, int /* narg */, char ** /* arg */, int tr
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
error->all(FLERR, "Illegal minimize style");
|
error->all(FLERR, "Unknown minimize style {}", style);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ----------------------------------------------------------------------
|
/* ----------------------------------------------------------------------
|
||||||
|
|||||||
Reference in New Issue
Block a user