ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning`
@ 2024-02-06 20:42 kddnewton (Kevin Newton) via ruby-core
  2024-02-07 12:13 ` [ruby-core:116618] " Eregon (Benoit Daloze) via ruby-core
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: kddnewton (Kevin Newton) via ruby-core @ 2024-02-06 20:42 UTC (permalink / raw
  To: ruby-core; +Cc: kddnewton (Kevin Newton)

Issue #20242 has been reported by kddnewton (Kevin Newton).

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116618] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
@ 2024-02-07 12:13 ` Eregon (Benoit Daloze) via ruby-core
  2024-02-09 21:43 ` [ruby-core:116662] " kddnewton (Kevin Newton) via ruby-core
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: Eregon (Benoit Daloze) via ruby-core @ 2024-02-07 12:13 UTC (permalink / raw
  To: ruby-core; +Cc: Eregon (Benoit Daloze)

Issue #20242 has been updated by Eregon (Benoit Daloze).


Do you have an example? That could help to clarify the need for this.
Is it problematic to modify these tests/specs to accept Prism warnings too? I think that would be best (since it would be needed longer-term anyway).
For compatibility, `--parser=prism` should at some point pass the test suite and specs, so that will mean some modifications to expected warning/parse errors.

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106630

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116662] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
  2024-02-07 12:13 ` [ruby-core:116618] " Eregon (Benoit Daloze) via ruby-core
@ 2024-02-09 21:43 ` kddnewton (Kevin Newton) via ruby-core
  2024-02-12  9:27 ` [ruby-core:116673] " Eregon (Benoit Daloze) via ruby-core
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: kddnewton (Kevin Newton) via ruby-core @ 2024-02-09 21:43 UTC (permalink / raw
  To: ruby-core; +Cc: kddnewton (Kevin Newton)

Issue #20242 has been updated by kddnewton (Kevin Newton).


I think you misunderstood what I'm asking for. Right now CRuby warns with:

```
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.
```

when you pass `--parser=prism`. I'm specifically asking to turn this off with `--parser=prism_without_warning`. I'm not asking to change the warning messages within Ruby itself.

The specs assert against the output of stderr, which means if this warning gets emitted, a lot of them fail. Specifically there are 70 specs that fail when this warning is present. In order to run the spec suite, I am currently manually commenting this out and recompiling.

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106672

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116673] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
  2024-02-07 12:13 ` [ruby-core:116618] " Eregon (Benoit Daloze) via ruby-core
  2024-02-09 21:43 ` [ruby-core:116662] " kddnewton (Kevin Newton) via ruby-core
@ 2024-02-12  9:27 ` Eregon (Benoit Daloze) via ruby-core
  2024-02-14 11:04 ` [ruby-core:116741] " mame (Yusuke Endoh) via ruby-core
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: Eregon (Benoit Daloze) via ruby-core @ 2024-02-12  9:27 UTC (permalink / raw
  To: ruby-core; +Cc: Eregon (Benoit Daloze)

Issue #20242 has been updated by Eregon (Benoit Daloze).


Oh right, that makes a lot more sense.
I wonder if it could be a configure flag or so to disable that warning, until it's stable enough to remove the warning entirely.

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106687

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116741] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
                   ` (2 preceding siblings ...)
  2024-02-12  9:27 ` [ruby-core:116673] " Eregon (Benoit Daloze) via ruby-core
@ 2024-02-14 11:04 ` mame (Yusuke Endoh) via ruby-core
  2024-02-14 15:02 ` [ruby-core:116754] " kddnewton (Kevin Newton) via ruby-core
  2024-02-14 15:33 ` [ruby-core:116755] " kddnewton (Kevin Newton) via ruby-core
  5 siblings, 0 replies; 7+ messages in thread
From: mame (Yusuke Endoh) via ruby-core @ 2024-02-14 11:04 UTC (permalink / raw
  To: ruby-core; +Cc: mame (Yusuke Endoh)

Issue #20242 has been updated by mame (Yusuke Endoh).


This issue was discussed at the dev meeting. No one agreed with `--parser=prism_without_warning` because it is too ad-hoc.

How about putting the warning in the "experimental" category? `ruby -W:no-experimental --parser=prism` will prevent the warning.

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106760

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116754] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
                   ` (3 preceding siblings ...)
  2024-02-14 11:04 ` [ruby-core:116741] " mame (Yusuke Endoh) via ruby-core
@ 2024-02-14 15:02 ` kddnewton (Kevin Newton) via ruby-core
  2024-02-14 15:33 ` [ruby-core:116755] " kddnewton (Kevin Newton) via ruby-core
  5 siblings, 0 replies; 7+ messages in thread
From: kddnewton (Kevin Newton) via ruby-core @ 2024-02-14 15:02 UTC (permalink / raw
  To: ruby-core; +Cc: kddnewton (Kevin Newton)

Issue #20242 has been updated by kddnewton (Kevin Newton).


That works for me, thanks!

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106777

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [ruby-core:116755] [Ruby master Misc#20242] `--parser=prism_without_warning`
  2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
                   ` (4 preceding siblings ...)
  2024-02-14 15:02 ` [ruby-core:116754] " kddnewton (Kevin Newton) via ruby-core
@ 2024-02-14 15:33 ` kddnewton (Kevin Newton) via ruby-core
  5 siblings, 0 replies; 7+ messages in thread
From: kddnewton (Kevin Newton) via ruby-core @ 2024-02-14 15:33 UTC (permalink / raw
  To: ruby-core; +Cc: kddnewton (Kevin Newton)

Issue #20242 has been updated by kddnewton (Kevin Newton).


I've added the PR here: https://github.com/ruby/ruby/pull/9963.

@mame would you mind reviewing? I had to add `rb_warning_category_update(opt->warn.mask, opt->warn.set);` when the `-W` option is passed because it needs to get updated before `ruby_opt_init` is called in order to properly track the state of the warning category. I hope that's okay.

----------------------------------------
Misc #20242: `--parser=prism_without_warning`
https://bugs.ruby-lang.org/issues/20242#change-106778

* Author: kddnewton (Kevin Newton)
* Status: Open
* Priority: Normal
----------------------------------------
I was hoping to add another option to `--parser` which would be `--parser=prism_without_warning`. The issue is that it's making it hard to run the tests/specs that test against the output of stderr. This would do the exact same thing as `--parser=prism` it just wouldn't warn. (The name is derived from `--dump=insns_without_opt`, but I'm okay with anything.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-02-14 15:33 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-06 20:42 [ruby-core:116610] [Ruby master Misc#20242] `--parser=prism_without_warning` kddnewton (Kevin Newton) via ruby-core
2024-02-07 12:13 ` [ruby-core:116618] " Eregon (Benoit Daloze) via ruby-core
2024-02-09 21:43 ` [ruby-core:116662] " kddnewton (Kevin Newton) via ruby-core
2024-02-12  9:27 ` [ruby-core:116673] " Eregon (Benoit Daloze) via ruby-core
2024-02-14 11:04 ` [ruby-core:116741] " mame (Yusuke Endoh) via ruby-core
2024-02-14 15:02 ` [ruby-core:116754] " kddnewton (Kevin Newton) via ruby-core
2024-02-14 15:33 ` [ruby-core:116755] " kddnewton (Kevin Newton) via ruby-core

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).