summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-02-05 10:14:10 +0100
committerGitHub <noreply@github.com>2022-02-05 10:14:10 +0100
commita0c87d4c114002ead8362ef1fa3a647282a725de (patch)
tree0fa44961bd785581e4fadff01a695ec260fdd20f /core
parent9fd095011ed27c7f6bd7f20cf6f18025cb8b1971 (diff)
parent1305ff92f79f3ae4d84e8a92f5caedda94e076cb (diff)
Merge pull request #57620 from Haydoggo/expression-exp-fix
Fix Expression's parsing of positive exponent literals
Diffstat (limited to 'core')
-rw-r--r--core/math/expression.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/core/math/expression.cpp b/core/math/expression.cpp
index b447d09887..0ddac9744e 100644
--- a/core/math/expression.cpp
+++ b/core/math/expression.cpp
@@ -361,6 +361,7 @@ Error Expression::_get_token(Token &r_token) {
is_float = true;
} else if (c == 'e') {
reading = READING_EXP;
+ is_float = true;
} else {
reading = READING_DONE;
}
@@ -397,9 +398,6 @@ Error Expression::_get_token(Token &r_token) {
exp_beg = true;
} else if ((c == '-' || c == '+') && !exp_sign && !exp_beg) {
- if (c == '-') {
- is_float = true;
- }
exp_sign = true;
} else {