summaryrefslogtreecommitdiff
path: root/template/sizes.c.tmpl
diff options
context:
space:
mode:
authorBenoit Daloze <eregontp@gmail.com>2021-04-29 14:31:05 +0200
committerBenoit Daloze <eregontp@gmail.com>2021-05-04 14:56:55 +0200
commit68d6bd0873557c12bec6f8e0f8db622f1499d8a7 (patch)
treedd50dae6ebbf714d19e3db7272f0d9b6af86223e /template/sizes.c.tmpl
parent229cbeba8c928dc6ee5eb21951e00c43a6e5225c (diff)
downloadruby-68d6bd0873557c12bec6f8e0f8db622f1499d8a7.tar.gz
Fix trivial -Wundef warnings
* See [Feature #17752] Co-authored-by: xtkoba (Tee KOBAYASHI) <xtkoba+ruby@gmail.com>
Diffstat (limited to 'template/sizes.c.tmpl')
-rw-r--r--template/sizes.c.tmpl2
1 files changed, 1 insertions, 1 deletions
diff --git a/template/sizes.c.tmpl b/template/sizes.c.tmpl
index 848a29f4be..31060f5fea 100644
--- a/template/sizes.c.tmpl
+++ b/template/sizes.c.tmpl
@@ -43,7 +43,7 @@ Init_sizeof(void)
% next
% end
% cond = conditions[type]
-#if SIZEOF_<%= type.tr_cpp %> != 0<%= " && #{cond}" if cond %>
+#if defined(SIZEOF_<%= type.tr_cpp %>) && SIZEOF_<%= type.tr_cpp %> != 0<%= " && #{cond}" if cond %>
DEFINE(<%= type %>, <%= type.tr_cpp %>);
#endif
% end