diff options
author | 卜部昌平 <shyouhei@ruby-lang.org> | 2020-08-11 11:45:54 +0900 |
---|---|---|
committer | 卜部昌平 <shyouhei@ruby-lang.org> | 2020-08-11 16:51:07 +0900 |
commit | 5af983af4f7722845f73b426cb33b7ba91a1c47c (patch) | |
tree | c8dfa19656597918854c4e2bf54c43cb6a745378 | |
parent | ef2b785b2dd188196e91dd7084a4ac4da42228f2 (diff) | |
download | ruby-5af983af4f7722845f73b426cb33b7ba91a1c47c.tar.gz |
template/prelude.c.tmpl: suppress clang-12 warning
Clang 12 warns "suspicious concatenation of string literals in an array
initialization", which is rather annoying than useful in this context.
-rw-r--r-- | template/prelude.c.tmpl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/template/prelude.c.tmpl b/template/prelude.c.tmpl index 73d35fc282..0ba6b0ba4b 100644 --- a/template/prelude.c.tmpl +++ b/template/prelude.c.tmpl @@ -81,6 +81,10 @@ Prelude.new(output, ARGV, vpath).instance_eval do #include "ruby/ruby.h" #include "vm_core.h" +COMPILER_WARNING_PUSH +#if __has_warning("-Wstring-concatenation") +COMPILER_WARNING_IGNORED(-Wstring-concatenation) +#endif % preludes = @preludes.values.sort % preludes.each {|i, prelude, lines, sub| @@ -116,6 +120,8 @@ static const struct { }; % } +COMPILER_WARNING_POP + % if @have_sublib #define PRELUDE_COUNT <%=preludes.size%> |