Project

General

Profile

ActionsLike0

Bug #12411

closed

Warnings when compiling transcode.c on cygwin

Added by duerst (Martin Dürst) over 8 years ago. Updated over 8 years ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 2.4.0dev (2016-05-22 trunk 55111) [x86_64-cygwin]
[ruby-core:75664]

Description

When compiling ruby trunk, the compilation of transcode produces the warnings below.
There's also a similar warning for dbm.c and a lot of them in some tkl files.

compiling transcode.c
In file included from ./include/ruby.h:33:0,
                 from internal.h:15,
                 from transcode.c:12:
transcode.c: In function ‘econv_args’:
transcode.c:3007:44: warning: initialization discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
     argc = rb_scan_args(argc, argv, "21:", snamev_p, dnamev_p, &flags_v, &opt);
                                            ^
./include/ruby/ruby.h:2156:56: note: in definition of macro ‘rb_scan_args’
         rb_scan_args0(argc,argv,fmt,(sizeof((VALUE*[]){__VA_ARGS__})/sizeof(VALUE*)),(VALUE*[]){__VA_ARGS__}), \
                                                        ^
transcode.c:3007:54: warning: initialization discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
     argc = rb_scan_args(argc, argv, "21:", snamev_p, dnamev_p, &flags_v, &opt);
                                                      ^
./include/ruby/ruby.h:2156:56: note: in definition of macro ‘rb_scan_args’
         rb_scan_args0(argc,argv,fmt,(sizeof((VALUE*[]){__VA_ARGS__})/sizeof(VALUE*)),(VALUE*[]){__VA_ARGS__}), \
                                                        ^
transcode.c:3007:44: warning: initialization discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
     argc = rb_scan_args(argc, argv, "21:", snamev_p, dnamev_p, &flags_v, &opt);
                                            ^
./include/ruby/ruby.h:2156:97: note: in definition of macro ‘rb_scan_args’
         rb_scan_args0(argc,argv,fmt,(sizeof((VALUE*[]){__VA_ARGS__})/sizeof(VALUE*)),(VALUE*[]){__VA_ARGS__}), \
                                                                                                 ^
transcode.c:3007:54: warning: initialization discards ‘volatile’ qualifier from pointer target type [-Wdiscarded-qualifiers]
     argc = rb_scan_args(argc, argv, "21:", snamev_p, dnamev_p, &flags_v, &opt);
                                                      ^
./include/ruby/ruby.h:2156:97: note: in definition of macro ‘rb_scan_args’
         rb_scan_args0(argc,argv,fmt,(sizeof((VALUE*[]){__VA_ARGS__})/sizeof(VALUE*)),(VALUE*[]){__VA_ARGS__}), \
                                                                                                 ^
transcode.c: At top level:
cc1: warning: unrecognized command line option ‘-Wno-self-assign’
cc1: warning: unrecognized command line option ‘-Wno-constant-logical-operand’
cc1: warning: unrecognized command line option ‘-Wno-parentheses-equality’
cc1: warning: unrecognized command line option ‘-Wno-tautological-compare’
compiling util.c

Related issues 1 (0 open1 closed)

Related to Ruby master - Bug #15162: Encoding::Converter.search_convpath(Encoding::ASCII_8BIT, Encoding::Emacs_Mule) crashes on MinGWClosedActions

Added by nobu (Nobuyoshi Nakada) over 8 years ago

Revision 6ce18e3a

transcode.c: GC guards

  • transcode.c (enc_arg, str_transcode_enc_args, econv_args):
    remove volatile, and add GC guards in callers.
    [ruby-core:75664] [Bug #12411]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Added by nagachika (Tomoyuki Chikanaga) over 8 years ago

Revision 83dc5915

merge revision(s) 55115: [Backport #12411]

    * transcode.c (enc_arg, str_transcode_enc_args, econv_args):
      remove volatile, and add GC guards in callers.
      [ruby-core:75664] [Bug #12411]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_3@55903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Added by U.Nakamura over 8 years ago

Revision b9892d1b

merge revision(s) 55115: [Backport #12411]

    * transcode.c (enc_arg, str_transcode_enc_args, econv_args):
      remove volatile, and add GC guards in callers.
      [ruby-core:75664] [Bug #12411]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

ActionsLike0

Also available in: Atom PDF