aboutsummaryrefslogtreecommitdiff
path: root/conform/conformtest.py
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2024-12-31 15:26:12 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2025-01-03 09:53:53 -0300
commit8ed53717c4f0a480f4d53e8baae91bcb98a962ce (patch)
tree2fadb8dd1db9b55aa6b93f93851554f21618a488 /conform/conformtest.py
parente9eea05986e4a02f1169ef0775c1d05802c5287f (diff)
downloadglibc-8ed53717c4f0a480f4d53e8baae91bcb98a962ce.tar.xz
glibc-8ed53717c4f0a480f4d53e8baae91bcb98a962ce.zip
conform: Do not use __SIG_ATOMIC_TYPE__
clang does not define __SIG_ATOMIC_TYPE__, instead add another directive ('size:') which instruct to use an integer type of defined minimum size. Reviewed-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'conform/conformtest.py')
-rw-r--r--conform/conformtest.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/conform/conformtest.py b/conform/conformtest.py
index 531c73a750..a14ffb86dd 100644
--- a/conform/conformtest.py
+++ b/conform/conformtest.py
@@ -172,6 +172,10 @@ class ConstantTest(object):
c_type = self.c_type[len('promoted:'):]
text = ('__typeof__ ((%s) 0 + (%s) 0) a2_%d;\n'
% (c_type, c_type, self.num))
+ elif self.c_type.startswith('size:'):
+ c_type = "int{}_t".format(self.c_type[len('size:'):])
+ text = ('__typeof__ ((%s) 0 + (%s) 0) a2_%d;\n'
+ % (c_type, c_type, self.num))
else:
text = '__typeof__ ((%s) 0) a2_%d;\n' % (self.c_type, self.num)
text += 'extern __typeof__ (%s) a2_%d;\n' % (self.symbol, self.num)