diff options
author | Kevin Newton <[email protected]> | 2024-06-07 10:10:12 -0400 |
---|---|---|
committer | Kevin Newton <[email protected]> | 2024-06-07 12:24:05 -0400 |
commit | 792e9c46a410332e261ec52f8beba3e1522b20da (patch) | |
tree | 9a3cba74b63436c24f87f1d735843b93ed812265 /ruby.c | |
parent | caac56584ccafd9a103f79a1fc9d389fe438181f (diff) |
Remove prism compiler warning
Diffstat (limited to 'ruby.c')
-rw-r--r-- | ruby.c | 27 |
1 files changed, 3 insertions, 24 deletions
@@ -2099,27 +2099,6 @@ process_script(ruby_cmdline_options_t *opt) } /** - * Call ruby_opt_init to set up the global state based on the command line - * options, and then warn if prism is enabled and the experimental warning - * category is enabled. - */ -static void -prism_opt_init(ruby_cmdline_options_t *opt) -{ - ruby_opt_init(opt); - - if (rb_warning_category_enabled_p(RB_WARN_CATEGORY_EXPERIMENTAL)) { - rb_category_warn( - RB_WARN_CATEGORY_EXPERIMENTAL, - "The compiler based on the Prism parser is currently experimental " - "and compatibility with the compiler based on parse.y is not yet " - "complete. Please report any issues you find on the `ruby/prism` " - "issue tracker." - ); - } -} - -/** * Process the command line options and parse the script into the given result. * Raise an error if the script cannot be parsed. */ @@ -2147,14 +2126,14 @@ prism_script(ruby_cmdline_options_t *opt, pm_parse_result_t *result) pm_options_command_line_set(options, command_line); pm_options_filepath_set(options, "-"); - prism_opt_init(opt); + ruby_opt_init(opt); error = pm_parse_stdin(result); } else if (opt->e_script) { command_line |= PM_OPTIONS_COMMAND_LINE_E; pm_options_command_line_set(options, command_line); - prism_opt_init(opt); + ruby_opt_init(opt); result->node.coverage_enabled = 0; error = pm_parse_string(result, opt->e_script, rb_str_new2("-e")); } @@ -2166,7 +2145,7 @@ prism_script(ruby_cmdline_options_t *opt, pm_parse_result_t *result) // line options. We do it in this order so that if the main script fails // to load, it doesn't require files required by -r. if (NIL_P(error)) { - prism_opt_init(opt); + ruby_opt_init(opt); error = pm_parse_file(result, opt->script_name); } |