Merge pull request #18321 from Crazy-P/Fixes-logically-dead-code

Fixes logically dead code (Coverity)
This commit is contained in:
Rémi Verschelde 2018-05-01 08:35:10 +02:00 committed by GitHub
commit 4cce6f3417
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 38 additions and 65 deletions

View file

@ -455,7 +455,7 @@ Error VisualScriptExpression::_get_token(Token &r_token) {
break;
}
if (cchar == '-' || (cchar >= '0' && cchar <= '9')) {
if (cchar >= '0' && cchar <= '9') {
//a number
String num;
@ -466,11 +466,6 @@ Error VisualScriptExpression::_get_token(Token &r_token) {
#define READING_DONE 4
int reading = READING_INT;
if (cchar == '-') {
num += '-';
cchar = GET_CHAR();
}
CharType c = cchar;
bool exp_sign = false;
bool exp_beg = false;