Skip to content

Commit 92be76e

Browse files
Markus Pfeifferfingolfin
authored andcommitted
Export READ_ALL_COMMANDS via header file
1 parent 380c633 commit 92be76e

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

src/streams.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,7 @@ static Int READ_COMMAND(Obj *evalResult)
125125
** that can read a single command from a stream without losing the rest of
126126
** its content.
127127
*/
128-
Obj FuncREAD_ALL_COMMANDS(
129-
Obj self, Obj instream, Obj echo, Obj capture, Obj resultCallback)
128+
Obj READ_ALL_COMMANDS(Obj instream, Obj echo, Obj capture, Obj resultCallback)
130129
{
131130
ExecStatus status;
132131
UInt dualSemicolon;
@@ -202,6 +201,13 @@ Obj FuncREAD_ALL_COMMANDS(
202201
return resultList;
203202
}
204203

204+
Obj FuncREAD_ALL_COMMANDS(
205+
Obj self, Obj instream, Obj echo, Obj capture, Obj resultCallback)
206+
{
207+
return READ_ALL_COMMANDS(instream, echo, capture, resultCallback);
208+
}
209+
210+
205211
/*
206212
Returns a list with one or two entries. The first
207213
entry is set to "false" if there was any error

src/streams.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,11 @@ extern Obj READ_AS_FUNC ( void );
4242
*/
4343
extern Int READ_GAP_ROOT ( const Char * filename );
4444

45+
// READ_ALL_COMMANDS reads a string of GAP statements and executes them
46+
// allowing to capture and process outputs
47+
extern Obj
48+
READ_ALL_COMMANDS(Obj instream, Obj echo, Obj capture, Obj resultCallback);
49+
4550

4651
/****************************************************************************
4752
**

0 commit comments

Comments
 (0)