genmatch.c (enum tree_code): Remove CONVERT{0,1,2} and VIEW_CONVERT{0,1,2}.
authorRichard Biener <rguenther@suse.de>
Fri, 6 Dec 2019 10:25:08 +0000 (10:25 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Fri, 6 Dec 2019 10:25:08 +0000 (10:25 +0000)
commit28fabd43d9d249134244eb9d7815917c7ae44b64
tree03e1b33743852bf29efdbf9d132485c89ed6ea0a
parentf7f6be76baf19eab6830870f4a63e17755552577
genmatch.c (enum tree_code): Remove CONVERT{0,1,2} and VIEW_CONVERT{0,1,2}.

2019-12-06  Richard Biener  <rguenther@suse.de>

* genmatch.c (enum tree_code): Remove CONVERT{0,1,2} and
VIEW_CONVERT{0,1,2}.
(expr::opt_grp): Add and initialize.
(lower_opt_convert): Rename to ...
(lower_opt): ... and work on opt_grp, simply switching operations
from being optional to being present or not.
(has_opt_convert): Rename to ...
(has_opt): ... and adjust.
(parser::parse_operation): Return the optional opt_grp,
remove special-casing of conditional operations and more generally
parse [digit]'?'.
(parser::parse_expr): Stick on the parsed opt_grp and perform
rough verification.
(parser::parse_for): Remove now unnecessary code.
(main): Likewise.
* doc/match-and-simplify.texi: Mention ? now works on all
unary operations and also match predicates.

From-SVN: r279037
gcc/ChangeLog
gcc/doc/match-and-simplify.texi
gcc/genmatch.c