diff src/audacious/tuple_compiler.h @ 3489:9580bb3e58fa trunk

Tuple handling API changed to include support for "hardcoded" fields.
author Matti Hamalainen <ccr@tnsp.org>
date Sat, 01 Sep 2007 07:08:21 +0300
parents 86dafe2300f7
children 6f67258c43fd
line wrap: on
line diff
--- a/src/audacious/tuple_compiler.h	Fri Aug 31 22:54:13 2007 +0100
+++ b/src/audacious/tuple_compiler.h	Sat Sep 01 07:08:21 2007 +0300
@@ -55,7 +55,7 @@
     VAR_CONST,
     VAR_DEF
 };
-    
+
 
 /* Caching structure for deterministic functions
  */
@@ -68,10 +68,12 @@
 
 typedef struct {
     gchar *name;
-    gboolean islocal;		/* Local? true = will be cleaned with tuple_evalctx_reset() */
-    gint type;			/* Type of this "variable", see VAR_* */
-    gchar *defval;
-    TupleValue *dictref;	/* Cached tuple value ref */
+    gboolean istemp;		/* Scope of variable - TRUE = temporary */
+    gint type;			/* Type of variable, see VAR_* */
+    gchar *defval;		/* Defined value ${=foo,bar} */
+
+    gint fieldidx;		/* if >= 0: Index # of "pre-defined" Tuple fields */
+    TupleValue *fieldref;	/* Cached tuple field ref */
 } TupleEvalVar;
 
 
@@ -95,7 +97,7 @@
 TupleEvalContext * tuple_evalctx_new(void);
 void tuple_evalctx_reset(TupleEvalContext *ctx);
 void tuple_evalctx_free(TupleEvalContext *ctx);
-gint tuple_evalctx_add_var(TupleEvalContext *ctx, gchar *name, gboolean islocal, gint type);
+gint tuple_evalctx_add_var(TupleEvalContext *ctx, const gchar *name, const gboolean istemp, const gint type);
 
 void tuple_evalnode_free(TupleEvalNode *expr);