potion  0.2
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
internal.c
Go to the documentation of this file.
1 
5 #include <stdio.h>
6 #include <stdlib.h>
7 #include <stdarg.h>
8 #include <errno.h>
9 #include "potion.h"
10 #include "internal.h"
11 #include "table.h"
12 #include "gc.h"
13 
20 #ifdef P2
21 PN PN_use, PN_no;
22 #endif
24 
25 PN potion_allocate(Potion *P, PN cl, PN self, PN len) {
26  struct PNData *obj = PN_ALLOC_N(PN_TUSER, struct PNData, PN_INT(len));
27  obj->siz = len;
28  return (PN)obj;
29 }
30 
31 static void potion_init(Potion *P) {
32  PN vtable, obj_vt, num_vt;
33  P->lobby = potion_type_new(P, PN_TLOBBY, 0); // named Lobby resp. P2
34  vtable = potion_type_new(P, PN_TVTABLE, P->lobby); // named Mixin
35  obj_vt = potion_type_new(P, PN_TOBJECT, P->lobby);
36  num_vt = potion_type_new(P, PN_TNUMBER, obj_vt);
37  potion_type_new(P, PN_TDOUBLE, num_vt);
38  potion_type_new(P, PN_TINTEGER, num_vt);
39  potion_type_new(P, PN_TNIL, obj_vt); // named NilKind resp. Undef
40  potion_type_new(P, PN_TBOOLEAN, obj_vt);
41  potion_type_new(P, PN_TSTRING, obj_vt);
42  potion_type_new(P, PN_TTABLE, obj_vt);
43  potion_type_new(P, PN_TCLOSURE, obj_vt);
44  potion_type_new(P, PN_TTUPLE, obj_vt);
45  potion_type_new(P, PN_TFILE, obj_vt);
46  potion_type_new(P, PN_TSTATE, obj_vt); // named Potion
47  potion_type_new(P, PN_TSOURCE, obj_vt);
48  potion_type_new(P, PN_TBYTES, obj_vt);
49  potion_type_new(P, PN_TPROTO, obj_vt);
50  potion_type_new(P, PN_TWEAK, obj_vt);
51  potion_type_new(P, PN_TLICK, obj_vt);
52  potion_type_new(P, PN_TERROR, obj_vt);
53  potion_type_new(P, PN_TCONT, obj_vt);
54 
56  PN_STR0 = PN_STRN("", 0);
57  PN_add = PN_STRN("+", 1);
58  PN_sub = PN_STRN("-", 1);
59  PN_mult = PN_STRN("*", 1);
60  PN_div = PN_STRN("/", 1);
61  PN_rem = PN_STRN("%", 1);
62  PN_bitn = PN_STRN("~", 1);
63  PN_bitl = PN_STRN("<<", 2);
64  PN_bitr = PN_STRN(">>", 2);
65  PN_if = PN_STRN("if", 2);
66  PN_def = PN_STRN("def", 3);
67  PN_cmp = PN_STRN("cmp", 3);
68  PN_call = PN_STRN("call", 4);
69  PN_else = PN_STRN("else", 4);
70  PN_loop = PN_STRN("loop", 4);
71  PN_self = PN_STRN("self", 4);
72  PN_name = PN_STRN("name", 4);
73  PN_size = PN_STRN("size", 4);
74  PN_break = PN_STRN("break", 5);
75  PN_class = PN_STRN("class", 5);
76  PN_elsif = PN_STRN("elsif", 5);
77  PN_print = PN_STRN("print", 5);
78  PN_while = PN_STRN("while", 5);
79  PN_length = PN_STRN("length", 6);
80  PN_return = PN_STRN("return", 6);
81  PN_string = PN_STRN("string", 6);
82  PN_lookup = PN_STRN("lookup", 6);
83  PN_number = PN_STRN("number", 6);
84  PN_extern = PN_STRN("extern", 6);
85  PN_compile = PN_STRN("compile", 7);
86  PN_integer = PN_STRN("integer", 7);
87  PN_allocate = PN_STRN("allocate", 8);
88  PN_continue = PN_STRN("continue", 8);
89  PN_delegated = PN_STRN("delegated", 9);
90 
92  potion_def_method(P, 0, vtable, PN_def, PN_FUNC(potion_def_method, "name=S,block=&"));
95 
96  potion_vm_init(P);
100 #ifndef DISABLE_CALLCC
101  potion_cont_init(P);
102 #endif
104  potion_num_init(P);
105  potion_str_init(P);
108  potion_lick_init(P);
110 #ifndef SANDBOX
111  potion_file_init(P);
113 #endif
114 
115  pn_filenames = PN_TUP0();
116 
117  GC_PROTECT(P);
118 }
119 
120 Potion *potion_create(void *sp) {
121  Potion *P = potion_gc_boot(sp); //zeros P
122  P->vt = PN_TSTATE;
123  P->uniq = (PNUniq)potion_rand_int();
124  PN_FLEX_NEW(P->vts, PN_TFLEX, PNFlex, TYPE_BATCH_SIZE);
125  PN_FLEX_SIZE(P->vts) = PN_TYPE_ID(PN_TUSER) + 1;
126  P->prec = PN_PREC;
127  P->fileno = -1;
128  //P->flags = (Potion_Flags)EXEC_VM;
129  potion_init(P);
130  return P;
131 }
132 
135 }
136 
137 PN potion_delegated(Potion *P, PN closure, PN self) {
138  PNType t = PN_FLEX_SIZE(P->vts) + PN_TNIL;
139  PN_FLEX_NEEDS(1, P->vts, PN_TFLEX, PNFlex, TYPE_BATCH_SIZE);
140  return potion_type_new(P, t, self);
141 }
142 
143 PN potion_call(Potion *P, PN cl, PN_SIZE argc, PN * volatile argv) {
144  vPN(Closure) c = PN_CLOSURE(cl);
145  switch (argc) {
146  case 0:
147  return c->method(P, cl, cl);
148  case 1:
149  return c->method(P, cl, argv[0]);
150  case 2:
151  return c->method(P, cl, argv[0], argv[1]);
152  case 3:
153  return c->method(P, cl, argv[0], argv[1], argv[2]);
154  case 4:
155  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3]);
156  case 5:
157  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4]);
158  case 6:
159  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
160  argv[5]);
161  case 7:
162  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
163  argv[5], argv[6]);
164  case 8:
165  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
166  argv[5], argv[6], argv[7]);
167  case 9:
168  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
169  argv[5], argv[6], argv[7], argv[8]);
170  case 10:
171  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
172  argv[5], argv[6], argv[7], argv[8], argv[9]);
173  case 11:
174  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
175  argv[5], argv[6], argv[7], argv[8], argv[9], argv[10]);
176  case 12:
177  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
178  argv[5], argv[6], argv[7], argv[8], argv[9], argv[10], argv[11]);
179  case 13:
180  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
181  argv[5], argv[6], argv[7], argv[8], argv[9], argv[10], argv[11],
182  argv[12]);
183  case 14:
184  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
185  argv[5], argv[6], argv[7], argv[8], argv[9], argv[10], argv[11],
186  argv[12], argv[13]);
187  case 15:
188  return c->method(P, cl, argv[0], argv[1], argv[2], argv[3], argv[4],
189  argv[5], argv[6], argv[7], argv[8], argv[9], argv[10], argv[11],
190  argv[12], argv[13], argv[14]);
191  }
192  return PN_NIL; // TODO: error "too many arguments"
193 }
194 
196  return potion_type(obj);
197 }
198 
203  switch (type) {
204  case PN_TNIL: return 'n'; //0 nil? (unused)
205  case PN_TNUMBER: return 'N'; //1 Number = Integer or Double
206  case PN_TBOOLEAN: return 'B'; //2 Boolean (unused)
207  case PN_TINTEGER: return 'I'; //3
208  case PN_TDOUBLE: return 'D'; //4
209  case PN_TSTRING: return 'S'; //5 String
210  case PN_TWEAK: return 0; //6 (illegal)
211  case PN_TCLOSURE: return '&'; //7
212  case PN_TTUPLE: return 'u'; //8 (used)
213  case PN_TSTATE: return 's'; //9
214  case PN_TFILE: return 'F'; //10
215  case PN_TOBJECT: return 'o'; //11 any (used)
216  case PN_TVTABLE: return 't'; //12 type (unused)
217  case PN_TSOURCE: return 'a'; //13 ast or code (used in source_compile)
218  case PN_TBYTES: return 'b'; //14 aio (used)
219  case PN_TPROTO: return 'P'; //15
220  case PN_TLOBBY: return 'l'; //16
221  case PN_TTABLE: return 'T'; //17 (used)
222  case PN_TLICK: return 'k'; //18
223  case PN_TFLEX: return 'f'; //19
224  case PN_TSTRINGS: return 'x'; //20
225  case PN_TERROR: return 'r'; //21
226  case PN_TCONT: return 'c'; //22
227  case PN_TUSER: return 'm'; //23 generated mixins (unused)
228  default: return 'm'; //23++
229  }
230 }
231 
232 PN potion_error(Potion *P, PN msg, long lineno, long charno, PN excerpt) {
233  struct PNError *e = PN_ALLOC(PN_TERROR, struct PNError);
234  e->message = msg;
235  e->line = PN_NUM(lineno);
236  e->chr = PN_NUM(charno);
237  e->excerpt = excerpt;
238  return (PN)e;
239 }
240 
242  vPN(Error) e = (struct PNError *)self;
243  if (e->excerpt == PN_NIL)
244  return potion_str_format(P, "** %s\n", PN_STR_PTR(e->message));
245  return potion_str_format(P, "** %s\n"
246  "** Where: (line %ld, character %ld) %s\n", PN_STR_PTR(e->message),
247  PN_INT(e->line), PN_INT(e->chr), PN_STR_PTR(e->excerpt));
248 }
249 
251  PN err_vt = PN_VTABLE(PN_TERROR);
252  potion_method(err_vt, "string", potion_error_string, 0);
253 }
254 
255 PN potion_io_error(Potion *P, const char *msg) {
256  return potion_error(P, potion_str_format(P, "Error %s: %s", msg, strerror(errno)),
257  0, 0, 0);
258 }
259 
260 static inline char *potion_type_name(Potion *P, PN obj) {
261  obj = potion_fwd(obj);
262  return PN_IS_PTR(obj)
264  : PN_IS_NIL(obj) ? "NilKind"
265  : PN_IS_INT(obj) ? "Integer"
266  : "Boolean";
267 }
268 
270  return potion_error(P, potion_str_format(P, "Invalid type %s", potion_type_name(P, obj)),
271  0, 0, 0);
272 }
273 PN potion_type_error_want(Potion *P, const char *param, PN obj, const char *type) {
274  return potion_error(P, potion_str_format(P, "Invalid type %s for %s, expected %s",
275  potion_type_name(P, obj), param, type),
276  0, 0, 0);
277 }
278 
279 #define PN_EXIT_ERROR 1
280 #define PN_EXIT_FATAL 2
281 
282 void potion_fatal(char *message) {
283  fprintf(stderr, "** %s\n", message);
284  exit(PN_EXIT_FATAL);
285 }
286 
287 // TODO: syntax errors should be collected and emitted at the end of the
288 // full compilation
289 void potion_syntax_error(Potion *P, struct PNSource *t, const char *fmt, ...) {
290  va_list args;
291  PN out = potion_bytes(P, 36);
292  ((struct PNBytes * volatile)out)->len = 0;
293  va_start(args, fmt);
294  pn_printf(P, out, fmt, args);
295  va_end(args);
296  fprintf(stderr, "** Syntax error: %s at \"%s\", line %d\n", PN_STR_PTR(out),
297  AS_STR(t->line), t->loc.lineno);
298  exit(PN_EXIT_FATAL);
299 }
300 
302  potion_fatal("Couldn't allocate memory.");
303 }
304 
305 // say
306 void potion_p(Potion *P, PN x) {
308  printf("\n");
309 }
310 
311 void potion_esp(void **esp) {
312  PN x;
313  *esp = (void *)&x;
314 }
315 
316 #ifdef DEBUG
317 void potion_dump(Potion *P, PN data) {
318  PN pd = potion_send(data, PN_string);
319  PN pt = potion_send(PN_VTABLE(PN_TYPE(data)), PN_string);
320  char *d = pd ? PN_STR_PTR(pd) : NIL_NAME;
321  char *t = pt ? PN_STR_PTR(pt) : NILKIND_NAME;
322  printf("%s (%s)\n", d, t);
323 }
324 #define pdump(data) potion_dump(P, data)
325 
327  long n;
328  PN *end, *ebp, *start = P->mem->cstack;
329  struct PNMemory *M = P->mem;
330  POTION_ESP(&end);
331  POTION_EBP(&ebp);
332 #if POTION_STACK_DIR > 0
333  n = end - start;
334 #else
335  n = start - end + 1;
336  start = end;
337  end = M->cstack;
338 #endif
339 
340  printf("-- dumping %ld stack from %p to %p --\n", n, start, end);
341  printf(" ebp = %p, *ebp = 0x%lx\n", ebp, *ebp);
342  while (n--) {
343  vPN(Object) o = (struct PNObject*)*start;
344  printf(" stack(%ld) = %p: 0x%lx", n, start, *start);
345  if (IS_GC_PROTECTED(*start))
346  printf(" vt=%x prot", PN_TYPE(o));
347  else if (IN_BIRTH_REGION(*start))
348  printf(" vt=%x birth", PN_TYPE(o));
349  else if (IN_OLDER_REGION(*start))
350  printf(" vt=%x OLD", PN_TYPE(o));
351 
352  if (*start == 0)
353  printf(" nil\n");
354  else if (*start & 1)
355  printf(" %ld INT\n", PN_INT(*start));
356  else if (*start & 2)
357  printf(" %s BOOL\n", *start == 2 ? "false" : "true");
358  else
359  printf(" \n");
360  start++;
361  }
362 }
363 #endif
PN PN_compile
Definition: internal.c:14
void potion_dump_stack(Potion *P)
Definition: internal.c:326
void potion_dump(Potion *P, PN data)
Definition: internal.c:317
PN PN_loop
Definition: internal.c:14
PN potion_delegated(Potion *P, PN closure, PN self)
Definition: internal.c:137
static void potion_init(Potion *P)
Definition: internal.c:31
#define PN_FLEX_NEW(N, V, T, S)
Definition: internal.h:35
PN potion_bytes(Potion *, size_t)
Definition: string.c:342
PN potion_def_method(Potion *P, PN closure, PN self, PN key, PN method)
define a method for a class
Definition: objmodel.c:346
PN PN_extern
Definition: internal.c:19
void potion_destroy(Potion *P)
Definition: internal.c:133
PN PN_return
Definition: internal.c:14
PN line
PNString of src line.
Definition: potion.h:438
#define PN_FLEX_NEEDS(X, N, V, T, S)
Definition: internal.h:40
byte strings are raw character data, volatile, may be appended/changed.
Definition: potion.h:338
void potion_table_init(Potion *)
Definition: table.c:821
#define vPN(t)
Definition: potion.h:132
#define PN_TSTATE
Definition: potion.h:116
#define PN_TSTRING
Definition: potion.h:112
#define PN_TCLOSURE
Definition: potion.h:114
unsigned long potion_rand_int(void)
generates a random number on [0,0xffffffff]-interval
Definition: mt19937ar.c:138
PN pn_filenames
Definition: internal.c:23
#define PN_ALLOC_N(V, T, C)
Definition: internal.h:13
PN PN_lookup
Definition: internal.c:14
#define PN_CLOSURE(x)
Definition: potion.h:216
PN PN_elsif
Definition: internal.c:14
#define PN_TUSER
Definition: potion.h:130
#define NIL_NAME
Definition: potion.h:149
PN PN_allocate
common method names in GC protected area
Definition: internal.c:14
PN potion_error_string(Potion *P, PN cl, PN self)
Definition: internal.c:241
struct to wrap arbitrary data that we may want to allocate from Potion.
Definition: potion.h:317
#define PN_EXIT_FATAL
Definition: internal.c:280
PN PN_cmp
Definition: internal.c:18
#define PN_TLICK
Definition: potion.h:125
PN PN_bitn
Definition: internal.c:17
void potion_lobby_init(Potion *P)
Definition: objmodel.c:682
#define potion_method(RCV, MSG, FN, SIG)
Definition: potion.h:780
void potion_cont_init(Potion *P)
Definition: callcc.c:169
#define PN_TFILE
Definition: potion.h:117
#define AS_STR(x)
Definition: potion.h:240
#define IN_BIRTH_REGION(p)
Definition: gc.h:52
#define PN_TCONT
Definition: potion.h:129
non-API GC internals
void potion_num_init(Potion *P)
Definition: number.c:439
#define PN_TNIL
Definition: potion.h:107
unsigned int PNUniq
Definition: potion.h:79
unsigned int PNType
Definition: potion.h:79
#define GC_PROTECT(P)
Definition: internal.h:137
PN PN_break
Definition: internal.c:14
static PN potion_fwd(PN)
the potion type is the 't' in the vtable tuple (m,t)
Definition: potion.h:561
#define TYPE_BATCH_SIZE
Definition: internal.h:33
struct PNMemory * mem
allocator/gc
Definition: potion.h:651
#define PN_TINTEGER
Definition: potion.h:111
char potion_type_char(PNType type)
valid signature types syntax.y: arg-type = ('s' | 'S' | 'n' | 'N' | 'b' | 'B' | 'k' | 't' | 'o' | 'O'...
Definition: internal.c:202
PN PN_integer
Definition: internal.c:19
PN_SIZE fileno
currently parsed file
Definition: potion.h:660
PN PN_add
Definition: internal.c:17
#define PN_TTUPLE
Definition: potion.h:115
PN excerpt
Definition: potion.h:493
PN PN_string
Definition: internal.c:14
void potion_file_init(Potion *P)
set Env global
Definition: file.c:189
#define PN_TFLEX
Definition: potion.h:126
#define PN_TBYTES
Definition: potion.h:121
#define PN_INT(x)
Definition: potion.h:205
#define PN_NUM(i)
Definition: potion.h:204
static char * potion_type_name(Potion *P, PN obj)
Definition: internal.c:260
void * cstack
machine stack start
Definition: potion.h:676
unsigned int PN_SIZE
Definition: potion.h:79
void potion_primitive_init(Potion *)
Definition: primitive.c:77
PN message
Definition: potion.h:491
standard objects act like C structs the fields are defined by the type and it's a fixed size...
Definition: potion.h:295
#define PN_IS_NIL(v)
Definition: potion.h:160
Potion * potion_gc_boot(void *sp)
Definition: gc.c:658
#define PN_TVTABLE
Definition: potion.h:119
int prec
double precision
Definition: potion.h:653
PN lobby
root namespace
Definition: potion.h:648
PN PN_size
Definition: internal.c:18
#define PN_TYPE_ID(t)
Definition: potion.h:135
#define PN_TOBJECT
Definition: potion.h:118
#define PN_TSOURCE
Definition: potion.h:120
void potion_lick_init(Potion *P)
Definition: lick.c:68
PN potion_io_error(Potion *P, const char *msg)
Definition: internal.c:255
#define M
Definition: mt19937ar.c:53
the garbage collector
Definition: potion.h:667
#define PN_TDOUBLE
Definition: potion.h:110
#define PN_FLEX_SIZE(N)
Definition: potion.h:231
PN potion_type_error(Potion *P, PN obj)
Definition: internal.c:269
PN PN_sub
Definition: internal.c:17
void potion_syntax_error(Potion *P, struct PNSource *t, const char *fmt,...)
Definition: internal.c:289
#define IN_OLDER_REGION(p)
Definition: gc.h:55
#define PN_TBOOLEAN
Definition: potion.h:109
#define PN_TWEAK
Definition: potion.h:113
PN_SIZE siz
Definition: potion.h:319
void potion_object_init(Potion *P)
Definition: objmodel.c:663
#define POTION_ESP(p)
Definition: internal.h:115
PN PN_mult
Definition: internal.c:17
PN potion_error(Potion *P, PN msg, long lineno, long charno, PN excerpt)
Definition: internal.c:232
non-API internal parts
PN PN_if
Definition: internal.c:14
PNFlex *volatile vts
built in types
Definition: potion.h:649
an error, including a description, file location, a brief excerpt.
Definition: potion.h:488
#define PN_IS_PTR(v)
Definition: potion.h:159
#define PN_TLOBBY
Definition: potion.h:123
PN potion_str_format(Potion *, const char *,...) __attribute__((format(printf
#define NILKIND_NAME
Definition: potion.h:150
void potion_esp(void **esp)
Definition: internal.c:311
PN chr
Definition: potion.h:492
PN potion_type_new(Potion *P, PNType t, PN self)
create a non-user type, derived from self
Definition: objmodel.c:207
#define PN_TSTRINGS
Definition: potion.h:127
Potion * potion_create(void *sp)
the potion API
Definition: internal.c:120
PN potion_call(Potion *P, PN cl, PN_SIZE argc, PN *volatile argv)
Definition: internal.c:143
PN line
Definition: potion.h:492
PN PN_call
Definition: internal.c:14
PN potion_allocate(Potion *P, PN cl, PN self, PN len)
Definition: internal.c:25
PN PN_delegated
Definition: internal.c:14
the global interpreter state P. currently singleton (not threads yet)
Definition: potion.h:644
#define PN_ALLOC(V, T)
Definition: internal.h:12
PN PN_div
Definition: internal.c:17
The potion API.
PN PN_def
Definition: internal.c:14
PN_SIZE pn_printf(Potion *, PN, const char *,...) __attribute__((format(printf
PN PN_while
Definition: internal.c:14
PNType potion_kind_of(PN obj)
Definition: internal.c:195
void potion_loader_init(Potion *P)
Definition: load.c:187
PN PN_class
Definition: internal.c:14
#define PN_TYPE(x)
Definition: potion.h:133
#define PN_TPROTO
Definition: potion.h:122
void potion_error_init(Potion *P)
Definition: internal.c:250
PN PN_print
Definition: internal.c:14
#define PN_IS_INT(v)
Definition: potion.h:162
void potion_str_init(Potion *)
Definition: string.c:491
#define IS_GC_PROTECTED(p)
Definition: gc.h:49
void potion_str_hash_init(Potion *)
Definition: string.c:487
static PNType potion_type(PN obj)
either immediate (NUM,BOOL,NIL) or a fwd
Definition: potion.h:523
the central table type, based on core/khash.h
PN PN_number
Definition: internal.c:18
void potion_compiler_init(Potion *P)
Definition: compile.c:1308
PN potion_lookup(Potion *P, PN closure, PN self, PN key)
used in bind and def_method
Definition: objmodel.c:391
#define potion_send(RCV, MSG, ARGS...)
method caches (more great stuff from ian piumarta)
Definition: potion.h:772
PN potion_type_error_want(Potion *P, const char *param, PN obj, const char *type)
Definition: internal.c:273
#define PN_STRN(x, l)
Definition: potion.h:211
void potion_source_init(Potion *P)
Definition: ast.c:157
void potion_p(Potion *P, PN x)
Definition: internal.c:306
PN PN_bitl
Definition: internal.c:17
#define PN_TTABLE
Definition: potion.h:124
void potion_allocation_error(void)
Definition: internal.c:301
volatile _PN PN
Definition: potion.h:81
PN PN_STR0
Definition: internal.c:18
PNType lineno
Definition: potion.h:435
#define PN_NIL
Definition: potion.h:139
PN PN_name
Definition: internal.c:18
#define PN_TNUMBER
Definition: potion.h:108
#define POTION_EBP(p)
Definition: internal.h:118
#define PN_FUNC(f, s)
Definition: potion.h:219
PN PN_else
Definition: internal.c:14
#define PN_TERROR
Definition: potion.h:128
struct PNSource::@1 loc
bitfield of fileno and lineno
PN PN_self
Definition: internal.c:14
PN PN_bitr
Definition: internal.c:17
void potion_vm_init(Potion *)
Definition: vm.c:129
void potion_fatal(char *message)
Definition: internal.c:282
const u8 args
Definition: compile.c:31
#define PN_STR_PTR(x)
Definition: potion.h:213
PN PN_continue
Definition: internal.c:14
#define PN_TUP0()
Definition: potion.h:261
#define PN_VTABLE(t)
Definition: potion.h:136
PN PN_rem
Definition: internal.c:17
PN PN_length
Definition: internal.c:18
void potion_gc_release(Potion *P)
Definition: gc.c:691
#define PN_PREC
Definition: potion.h:208