diff options
-rw-r--r-- | src/value.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/value.cc b/src/value.cc index 87b31cd6..97328c37 100644 --- a/src/value.cc +++ b/src/value.cc @@ -1228,7 +1228,7 @@ void value_t::in_place_cast(type_t cast_type) case STRING: switch (cast_type) { case INTEGER: { - if (all(as_string(), is_digit())) { + if (all(as_string(), is_any_of("-0123456789"))) { set_long(lexical_cast<long>(as_string())); return; } |