diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2018-02-21 21:08:31 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2018-02-21 21:08:31 (GMT) |
commit | fa2da7f91a8621fc20e172573fac5e801bcc6291 (patch) | |
tree | ae7cd3a2039ecf195d083b4ad8e078dc339d910d /fickle | |
parent | cc31166c228c174cbefcd53ac775dfd92825ea13 (diff) | |
download | blt-fa2da7f91a8621fc20e172573fac5e801bcc6291.zip blt-fa2da7f91a8621fc20e172573fac5e801bcc6291.tar.gz blt-fa2da7f91a8621fc20e172573fac5e801bcc6291.tar.bz2 |
add namespace
Diffstat (limited to 'fickle')
-rw-r--r-- | fickle/fickle.tcl | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/fickle/fickle.tcl b/fickle/fickle.tcl index 8bd2977..b10107b 100644 --- a/fickle/fickle.tcl +++ b/fickle/fickle.tcl @@ -499,6 +499,7 @@ proc write_scanner_utils {} { variable yy_done if \{\[string length \$yy_buffer\] - \$yy_index < $::BUFFER_SIZE\} \{ + set new_buffer \"\" set new_buffer_size 0 if \{\$yy_done == 0\} \{ YY_INPUT new_buffer new_buffer_size $::BUFFER_SIZE @@ -616,10 +617,11 @@ proc ${::p}::yylex \{\} \{ } puts $::dest " if \{\[string length \$yy_buffer\] - \$yy_index < $::BUFFER_SIZE\} \{ if \{\$yy_done == 0\} \{ - set ${::p}_new_buffer \"\" - YY_INPUT ${::p}_new_buffer ${::p}_buffer_size $::BUFFER_SIZE - append yy_buffer \$${::p}_new_buffer - if \{\$${::p}_buffer_size == 0 && \\ + set yy_buffer_size 0 + set yy_new_buffer \"\" + YY_INPUT yy_new_buffer yy_buffer_size $::BUFFER_SIZE + append yy_buffer \$yy_new_buffer + if \{\$yy_buffer_size == 0 && \\ \[string length \$yy_buffer\] - \$yy_index == 0\} \{ set yy_done 1 \} @@ -693,7 +695,7 @@ proc ${::p}::yylex \{\} \{ \}" if $::debugmode { puts $::dest " if \$yy_flex_debug \{ - puts stderr \" --accepting \$yyrule_num (\\\"\$yytext\\\")\" + puts stderr \" ${::p} --accepting \$yyrule_num (\\\"\$yytext\\\")\" \}" } if $::linenums { |