]> granicus.if.org Git - re2c/commit
Allow tags in any part of regexp, not only on top-level concatenation.
authorUlya Trofimovich <skvadrik@gmail.com>
Thu, 5 May 2016 16:17:06 +0000 (17:17 +0100)
committerUlya Trofimovich <skvadrik@gmail.com>
Thu, 5 May 2016 16:17:06 +0000 (17:17 +0100)
commit04b37b1bbcb290ff3a0f4e4ada395bbd6d2775c6
treeef4a44b279b383b1e0c1d9b93615adf05419d3e3
parent4ba792fe7f7a945add71211beb5b2e75673dd307
Allow tags in any part of regexp, not only on top-level concatenation.

Fixed-length tag optimization applies only to top-level concatenation:
since we cannot predict which path lexer will choose, we cannot be
sure that any tags except top-level concatenation will ever be
initialized. If a tag may be uninitialized, we cannot fix other
tags on this one (we cannot even fix same-level tags relative to
each other, because fixed tags won't preserve the default value).
32 files changed:
re2c/Makefile.am
re2c/bootstrap/src/parse/lex.cc
re2c/bootstrap/src/parse/parser.cc
re2c/bootstrap/src/parse/y.tab.h
re2c/src/codegen/emit_action.cc
re2c/src/codegen/emit_dfa.cc
re2c/src/codegen/go_emit.cc
re2c/src/ir/adfa/adfa.cc
re2c/src/ir/adfa/adfa.h
re2c/src/ir/ctx.cc
re2c/src/ir/ctx.h
re2c/src/ir/dfa/context_deduplication.cc
re2c/src/ir/dfa/determinization.cc
re2c/src/ir/dfa/dfa.h
re2c/src/ir/nfa/init_rules.cc [new file with mode: 0644]
re2c/src/ir/nfa/make_tags.cc [new file with mode: 0644]
re2c/src/ir/nfa/nfa.cc
re2c/src/ir/nfa/nfa.h
re2c/src/ir/nfa/nullable.cc [new file with mode: 0644]
re2c/src/ir/nfa/regexps2nfa.cc [new file with mode: 0644]
re2c/src/ir/nfa/sizeof_regexps.cc [new file with mode: 0644]
re2c/src/ir/regexp/regexp.h
re2c/src/ir/regexp/split_charset.cc
re2c/src/ir/rule.cc
re2c/src/ir/rule.h
re2c/src/ir/skeleton/path.h
re2c/src/ir/skeleton/skeleton.cc
re2c/src/ir/skeleton/skeleton.h
re2c/src/parse/lex.re
re2c/src/parse/parser.ypp
re2c/test/contexts/syntax_error0.c
re2c/test/error12.c