From 3ade78fff6315977c0c75a458d351bfc85c34d92 Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 28 May 2017 09:49:29 +0000 Subject: [PATCH] ruby.c: shrink ruby_cmdline_options_t * ruby.c (ruby_cmdline_options_t): reordered members and turned simple flags into bit fields to reduce the size (136->104 on LP64). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ruby.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/ruby.c b/ruby.c index 5fb007334f..206ef9be12 100644 --- a/ruby.c +++ b/ruby.c @@ -122,15 +122,6 @@ enum dump_flag_bits { typedef struct ruby_cmdline_options ruby_cmdline_options_t; struct ruby_cmdline_options { - int sflag, xflag; - int do_loop, do_print; - int do_line, do_split; - int do_search; - unsigned int features; - int verbose; - int safe_level; - unsigned int setids; - unsigned int dump; const char *script; VALUE script_name; VALUE e_script; @@ -141,7 +132,18 @@ struct ruby_cmdline_options { } enc; } src, ext, intern; VALUE req_list; + unsigned int features; + unsigned int dump; + int safe_level; + int sflag, xflag; unsigned int warning: 1; + unsigned int verbose: 1; + unsigned int do_loop: 1; + unsigned int do_print: 1; + unsigned int do_line: 1; + unsigned int do_split: 1; + unsigned int do_search: 1; + unsigned int setids: 2; }; static void init_ids(ruby_cmdline_options_t *);