summaryrefslogtreecommitdiff
path: root/colm/pdarun.c
diff options
context:
space:
mode:
authorAdrian Thurston <thurston@complang.org>2013-02-02 11:08:17 -0500
committerAdrian Thurston <thurston@complang.org>2013-02-02 11:08:17 -0500
commit116b212223225cc519862330d42b2426737fb4f4 (patch)
tree31d20ba07e0338f4ad5286b64fe599224a53ffbb /colm/pdarun.c
parent2e74066ca8fb99c6fcccf210f8b9c2400a62e821 (diff)
downloadcolm-116b212223225cc519862330d42b2426737fb4f4.tar.gz
return pointer to data bclok from getParseBlock
The next step is to use this pointer instead of the scanBuf to do the scanning.
Diffstat (limited to 'colm/pdarun.c')
-rw-r--r--colm/pdarun.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/colm/pdarun.c b/colm/pdarun.c
index 5ff7921e..ace7b019 100644
--- a/colm/pdarun.c
+++ b/colm/pdarun.c
@@ -1094,9 +1094,12 @@ long scanToken( Program *prg, PdaRun *pdaRun, FsmRun *fsmRun, StreamImpl *is )
/* Get more data. */
int have = fsmRun->tokstart != 0 ? fsmRun->p - fsmRun->tokstart : 0;
- int len = 0;
+
debug( REALM_SCAN, "fetching data: have: %d space: %d\n", have, space );
- int type = is->funcs->getParseBlock( fsmRun, is, have, fsmRun->p, space, &len );
+
+ char *pd = 0;
+ int len = 0;
+ int type = is->funcs->getParseBlock( fsmRun, is, have, fsmRun->p, space, &pd, &len );
switch ( type ) {
case INPUT_DATA: