Commit f2995a5e authored by Eckhart Arnold's avatar Eckhart Arnold

- made ptype parameter implicit (again)

parent 93ed340e
......@@ -573,11 +573,11 @@ def reduce_single_child(node):
node.result = node.result[0].result
def replace_parser(node, parser_name, parser_type=''):
def replace_parser(node, name, ptype=''):
"""Replaces the parser of a Node to a mock parser with the given
name and pseudo-type.
"""
node.parser = MockParser(parser_name, parser_type)
node.parser = MockParser(name, ptype)
# ------------------------------------------------
......
......@@ -283,7 +283,7 @@ MLW_AST_transformation_table = {
[partial(remove_tokens, tokens={'AUTORIN', 'AUTOR'})],
"WORT, WORT_KLEIN, WORT_GROSS, GROSSSCHRIFT":
[remove_expendables, reduce_single_child],
"LEER, TRENNER, ZSPRUNG": partial(replace_parser, parser_name=WHITESPACE_KEYWORD),
"LEER, TRENNER, ZSPRUNG": partial(replace_parser, name='', ptype=WHITESPACE_PTYPE),
"DATEI_ENDE": no_operation,
"NIEMALS": no_operation,
(TOKEN_PTYPE, WHITESPACE_PTYPE):
......
......@@ -22,12 +22,12 @@
fa-rcu-tergula
</LVariante>
<LVZusatz>
<TOKEN__>
<:Token>
ZUSATZ
</TOKEN__>
<TOKEN__>
</:Token>
<:Token>
sim.
</TOKEN__>
</:Token>
</LVZusatz>
</LemmaVarianten>
<GrammatikPosition>
......@@ -78,9 +78,9 @@
</LemmaPosition>
<SchreibweisenPosition>
<SWTyp>
<TOKEN__>
<:Token>
script.
</TOKEN__>
</:Token>
</SWTyp>
<SWVariante>
<Schreibweise>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment