mirror of
https://github.com/red0124/ssp.git
synced 2025-01-23 13:05:20 +01:00
Update valid method for throw_on_error
This commit is contained in:
parent
5ab41c0315
commit
29c471e33a
@ -169,6 +169,8 @@ public:
|
|||||||
bool valid() const {
|
bool valid() const {
|
||||||
if constexpr (string_error) {
|
if constexpr (string_error) {
|
||||||
return error_.empty();
|
return error_.empty();
|
||||||
|
} else if constexpr (throw_on_error) {
|
||||||
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return !error_;
|
return !error_;
|
||||||
}
|
}
|
||||||
|
@ -63,6 +63,8 @@ public:
|
|||||||
bool valid() const {
|
bool valid() const {
|
||||||
if constexpr (string_error) {
|
if constexpr (string_error) {
|
||||||
return error_.empty();
|
return error_.empty();
|
||||||
|
} else if constexpr (throw_on_error) {
|
||||||
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return !error_;
|
return !error_;
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,8 @@ public:
|
|||||||
bool valid() const {
|
bool valid() const {
|
||||||
if constexpr (string_error) {
|
if constexpr (string_error) {
|
||||||
return error_.empty();
|
return error_.empty();
|
||||||
|
} else if constexpr (throw_on_error) {
|
||||||
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return !error_;
|
return !error_;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user