[PATCH] D75365: [AST Matchers] Fix bug in 'optionally' matcher wherein all previous bindings are cleared when all inner matchers fail.

Dmitri Gribenko via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 2 05:52:07 PST 2020


gribozavr2 added a comment.

+1 to this fix.

However, regarding `allOf` vs. `anyOf` semantics, since `optionally` always succeeds, is there a difference between the two semantics?

It seems to me that there should be no difference between `allOf(optionally(a), optionally(b))` vs. `anyOf(optionally(a), optionally(b))`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75365/new/

https://reviews.llvm.org/D75365





More information about the cfe-commits mailing list