]> granicus.if.org Git - re2c/commit
Introduced tag versioning.
authorUlya Trofimovich <skvadrik@gmail.com>
Sat, 22 Oct 2016 11:07:58 +0000 (12:07 +0100)
committerUlya Trofimovich <skvadrik@gmail.com>
Sat, 22 Oct 2016 12:19:13 +0000 (13:19 +0100)
commitf5a5b8cfe71e6d209ef25c97a722595f2035aae7
tree63005b62d669a32a4a4515f1b2a231ff35ef7ae1
parent262c22617c9c3d3ca1675b87b5434c770ad38322
Introduced tag versioning.

Instead of treating tag as boolean variable (true - present,
false - absent) we now allow it to have many versions. Special
version value 'TAGVER_ZERO' denotes tag absense (corresponds to
'false').

For now, each tag has exactly one version except 'TAGVER_ZERO':
tag's number plus one.

We need tag versions because with only two values it's impossible
to expess more subtle states, e.g. initialized / uninitialized.
Tag versions will also allow to treat fallback tags like any other
tags (in particular, allow them participate in deduplication).
In future, when we add nondeterministic tags, versions will be used
to implement tag copies.
46 files changed:
re2c/src/codegen/emit.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/adfa/prepare.cc
re2c/src/ir/compile.cc
re2c/src/ir/dfa/closure.cc
re2c/src/ir/dfa/dfa.h
re2c/src/ir/dfa/fallback_tags.cc
re2c/src/ir/dfa/tag_deduplication.cc
re2c/src/ir/nfa/init_rules.cc
re2c/src/ir/nfa/make_tags.cc
re2c/src/ir/skeleton/path.h
re2c/src/ir/skeleton/skeleton.cc
re2c/src/ir/skeleton/skeleton.h
re2c/src/ir/tag.cc
re2c/src/ir/tag.h
re2c/test/scanner_re2c_default.--emit-dot.c
re2c/test/tags/bug121_fix_multiple.i--tags--input(custom).c
re2c/test/tags/bug121_var_multiple.i--tags--input(custom).c
re2c/test/tags/bug121_var_multiple.i--tags.c
re2c/test/tags/conf1.i--tags--input(custom).c
re2c/test/tags/conf1.i--tags.c
re2c/test/tags/conf2.i--tags--input(custom).c
re2c/test/tags/conf2.i--tags.c
re2c/test/tags/conf3.i--tags--input(custom).c
re2c/test/tags/conf3.i--tags.c
re2c/test/tags/dedup4.i--tags.c
re2c/test/tags/dedup5.i--tags.c
re2c/test/tags/fallback1.i--tags.c
re2c/test/tags/fallback2.i--tags.c
re2c/test/tags/fallback3.i--tags.c
re2c/test/tags/fix2_trail.i--tags--input(custom).c
re2c/test/tags/fix3.i--tags.c
re2c/test/tags/fix3_trail.i--tags--input(custom).c
re2c/test/tags/fix3_trail.i--tags.c
re2c/test/tags/fix4.i--tags.c
re2c/test/tags/fix4_trail.i--tags--input(custom).c
re2c/test/tags/fix4_trail.i--tags.c
re2c/test/tags/fix5.i--tags.c
re2c/test/tags/fix5_trail.i--tags--input(custom).c
re2c/test/tags/fix5_trail.i--tags.c
re2c/test/tags/iter_plus.i--tags.c
re2c/test/tags/minimization.i.c