summaryrefslogtreecommitdiffstats
path: root/tests/bugs
diff options
context:
space:
mode:
authorkaizhangNV <149626564+kaizhangNV@users.noreply.github.com>2024-03-20 08:48:13 -0700
committerGitHub <noreply@github.com>2024-03-20 08:48:13 -0700
commit6cefb85bc32208fec1524a7d1cf3c20d8ce21c15 (patch)
treea7d7c64d75f586b1f52b5149a7f47c55af15273a /tests/bugs
parentf3b1161cb7b7d92d20eb947563a30c155c4c71a7 (diff)
Change representation of float literal in language translation (#3798)
* Change representation of float literal in language translation Fix the issue (#3490). Previous implementation could zero out the very small float literal. We now use scientific notation instead to represent the float numbers whose exponential part are larger than a threshold. In other cases, keep using fixed notation. --------- Co-authored-by: Yong He <yonghe@outlook.com>
Diffstat (limited to 'tests/bugs')
-rw-r--r--tests/bugs/gh-3589.slang4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/bugs/gh-3589.slang b/tests/bugs/gh-3589.slang
index 58bb74f37..4534465d3 100644
--- a/tests/bugs/gh-3589.slang
+++ b/tests/bugs/gh-3589.slang
@@ -11,8 +11,8 @@ void main(uint id: SV_DispatchThreadID)
outputBuffer[0] = i;
outputBuffer[1] = m;
- // CHECK: -179769313486231570814527423731704356798070567525844996598917476803157260780028538760589558632766878171540458953514382464234321326889464182768467546703537516986049910576551282076245490090389328944075868508455133942304583236903222948165808559332123348274797826204144723168738177180919299881250404026184124858368.0
+ // CHECK: -1.79769313486231571e+308
outputBuffer2[0] = double.minValue;
- // CHECK: 179769313486231570814527423731704356798070567525844996598917476803157260780028538760589558632766878171540458953514382464234321326889464182768467546703537516986049910576551282076245490090389328944075868508455133942304583236903222948165808559332123348274797826204144723168738177180919299881250404026184124858368.0
+ // CHECK: 1.79769313486231571e+308
outputBuffer2[1] = double.maxValue;
} \ No newline at end of file