mirror of
https://github.com/Cantera/cantera.git
synced 2025-02-25 18:55:29 -06:00
Add IndexError that omits array name
This commit is contained in:
parent
21ca5e1b26
commit
eb8d6595b8
@ -72,6 +72,9 @@ string ArraySizeError::getMessage() const
|
||||
|
||||
string IndexError::getMessage() const
|
||||
{
|
||||
if (arrayName_ == "") {
|
||||
return fmt::format("IndexError: {} outside valid range of 0 to {}.", m_, mmax_);
|
||||
}
|
||||
return fmt::format("IndexError: {}[{}] outside valid range of 0 to {}.",
|
||||
arrayName_, m_, mmax_);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user