This revision was automatically updated to reflect the committed changes.
sammccall marked an inline comment as done.
Closed by commit rG0360b9f1599b: [pseudo] (trivial) bracket-matching (authored
by sammccall).
Changed prior to commit:
https://reviews.llvm.org/D125911?vs=430440&id=431658#toc
sammccall marked 4 inline comments as done.
sammccall added inline comments.
Comment at: clang-tools-extra/pseudo/unittests/BracketTest.cpp:103
+TEST(Bracket, SimplePair) {
+ verifyBrackets("^{ ^[ ^( ^) ^( ^) ^] ^}");
+ verifyBrackets(") ^{ ^[ ^] ^} (");
hokei
hokein added inline comments.
Comment at: clang-tools-extra/pseudo/unittests/BracketTest.cpp:103
+TEST(Bracket, SimplePair) {
+ verifyBrackets("^{ ^[ ^( ^) ^( ^) ^] ^}");
+ verifyBrackets(") ^{ ^[ ^] ^} (");
sammccall wrote:
> hokein wrote:
> > For this simple
sammccall added inline comments.
Comment at: clang-tools-extra/pseudo/unittests/BracketTest.cpp:103
+TEST(Bracket, SimplePair) {
+ verifyBrackets("^{ ^[ ^( ^) ^( ^) ^] ^}");
+ verifyBrackets(") ^{ ^[ ^] ^} (");
hokein wrote:
> For this simple case, just using
hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.
Thanks, this looks a good start version!
Comment at: clang-tools-extra/pseudo/include/clang-pseudo/Bracket.h:9
+//
+// Bracket structure (particularly brackes) is key to isol
sammccall added a comment.
The Bracket struct & translation between token/bracket streams is not really
justified by the implementation in this patch.
Next patch will run nontrivial algorithms on the bracket strings.
Happy to scope this patch down (avoid that struct) or up (include the full
alg
sammccall created this revision.
sammccall added a reviewer: hokein.
Herald added a subscriber: mgorny.
Herald added a project: All.
sammccall requested review of this revision.
Herald added subscribers: cfe-commits, alextsao1999.
Herald added a project: clang-tools-extra.
Error-tolerant bracket m