From d490555ec9d5efb886211f735694d4e7dd0c166d Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 23 Nov 1994 12:32:00 -0200 Subject: garbage collection tag for strings organized in struct TaggedString --- opcode.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'opcode.h') diff --git a/opcode.h b/opcode.h index e26fcce1..f375c7d7 100644 --- a/opcode.h +++ b/opcode.h @@ -1,12 +1,13 @@ /* ** TeCGraf - PUC-Rio -** $Id: opcode.h,v 3.7 1994/11/10 17:11:52 roberto Exp roberto $ +** $Id: opcode.h,v 3.8 1994/11/10 17:36:54 roberto Exp roberto $ */ #ifndef opcode_h #define opcode_h #include "lua.h" +#include "tree.h" #ifndef STACKGAP #define STACKGAP 128 @@ -109,7 +110,7 @@ typedef union { Cfunction f; real n; - char *s; + TaggedString *ts; Byte *b; struct Hash *a; void *u; @@ -129,7 +130,8 @@ typedef struct /* Macros to access structure members */ #define tag(o) ((o)->tag) #define nvalue(o) ((o)->value.n) -#define svalue(o) ((o)->value.s) +#define svalue(o) ((o)->value.ts->str) +#define tsvalue(o) ((o)->value.ts) #define bvalue(o) ((o)->value.b) #define avalue(o) ((o)->value.a) #define fvalue(o) ((o)->value.f) -- cgit v1.2.3-55-g6feb