46 lines
1.4 KiB
Diff
46 lines
1.4 KiB
Diff
--- a/interpreter.h
|
|
+++ b/interpreter.h
|
|
@@ -173,6 +173,7 @@ struct ValueType
|
|
};
|
|
|
|
/* function definition */
|
|
+typedef struct Value Value; /* Needed to allow reference before definition */
|
|
struct FuncDef
|
|
{
|
|
struct ValueType *ReturnType; /* the return value type */
|
|
@@ -180,7 +181,12 @@ struct FuncDef
|
|
int VarArgs; /* has a variable number of arguments after the explicitly specified ones */
|
|
struct ValueType **ParamType; /* array of parameter types */
|
|
char **ParamName; /* array of parameter names */
|
|
- void (*Intrinsic)(); /* intrinsic call address or NULL */
|
|
+ void (*Intrinsic)( /* intrinsic call address or NULL */
|
|
+ struct ParseState *Parser,
|
|
+ Value *ReturnValue,
|
|
+ Value **ParamArray,
|
|
+ int ArgCount
|
|
+ );
|
|
struct ParseState Body; /* lexical tokens of the function body if not intrinsic */
|
|
};
|
|
|
|
@@ -610,8 +616,8 @@ void IncludeFile(Picoc *pc, char *Filename);
|
|
* void PicocIncludeAllSystemHeaders(); */
|
|
|
|
/* debug.c */
|
|
-void DebugInit();
|
|
-void DebugCleanup();
|
|
+void DebugInit(Picoc *pc);
|
|
+void DebugCleanup(Picoc *pc);
|
|
void DebugCheckStatement(struct ParseState *Parser);
|
|
|
|
|
|
--- a/platform/library_unix.c
|
|
+++ b/platform/library_unix.c
|
|
@@ -1,6 +1,6 @@
|
|
#include "../interpreter.h"
|
|
|
|
-void UnixSetupFunc()
|
|
+void UnixSetupFunc(Picoc *pc)
|
|
{
|
|
}
|
|
|