[libc-commits] [libc] [libc][z/OS] Remove ASCII trick to fix EBDIC std::from_char (PR #116078)

Zibi Sarbinowski via libc-commits libc-commits at lists.llvm.org
Wed Nov 13 09:56:22 PST 2024


https://github.com/zibi2 updated https://github.com/llvm/llvm-project/pull/116078

>From 0acf7ffa65c41325112c33cb1a6926d86d0ede45 Mon Sep 17 00:00:00 2001
From: Zbigniew Sarbinowski <zibi at ca.ibm.com>
Date: Wed, 13 Nov 2024 16:37:18 +0000
Subject: [PATCH 1/2] Remove ASCII trick to fix EBDIC std::from_char

---
 libc/src/__support/high_precision_decimal.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libc/src/__support/high_precision_decimal.h b/libc/src/__support/high_precision_decimal.h
index ac11649d1d1686..20088d6d797910 100644
--- a/libc/src/__support/high_precision_decimal.h
+++ b/libc/src/__support/high_precision_decimal.h
@@ -350,7 +350,8 @@ class HighPrecisionDecimal {
     if (!saw_dot)
       this->decimal_point = total_digits;
 
-    if (num_cur < num_len && ((num_string[num_cur] | 32) == 'e')) {
+    if (num_cur < num_len &&
+        (num_string[num_cur] == 'e' || num_string[num_cur] == 'E')) {
       ++num_cur;
       if (isdigit(num_string[num_cur]) || num_string[num_cur] == '+' ||
           num_string[num_cur] == '-') {

>From 8dd7a434e4f93e63cd4866856aed3ca5074aad0f Mon Sep 17 00:00:00 2001
From: Zbigniew Sarbinowski <zibi at ca.ibm.com>
Date: Wed, 13 Nov 2024 18:09:00 +0000
Subject: [PATCH 2/2] Empty commit to rerun CI.




More information about the libc-commits mailing list