summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/slang/slang-parser.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/slang/slang-parser.cpp b/source/slang/slang-parser.cpp
index bb70347c9..aff1d832d 100644
--- a/source/slang/slang-parser.cpp
+++ b/source/slang/slang-parser.cpp
@@ -4044,7 +4044,7 @@ namespace Slang
suffixType = parser->getSession()->getErrorType();
}
// `f` suffix -> `float`
- if(fCount == 1 && !lCount)
+ if(fCount == 1 && !lCount && !hCount)
{
suffixType = parser->getSession()->getFloatType();
}
@@ -4054,7 +4054,7 @@ namespace Slang
suffixType = parser->getSession()->getDoubleType();
}
// `h` or `hf` suffix on floating-point literal -> `half`
- else if(lCount == 1 && (fCount <= 1))
+ else if(hCount == 1 && (fCount <= 1))
{
suffixType = parser->getSession()->getHalfType();
}