1 /* 2 * Copyright 1993, 2000 Christopher Seiwald. 3 * 4 * This file is part of Jam - see jam.c for Copyright information. 5 */ 6 7 /* This file is ALSO: 8 * Copyright 2001-2004 David Abrahams. 9 * Distributed under the Boost Software License, Version 1.0. 10 * (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) 11 */ 12 13 /* 14 * compile.h - compile parsed jam statements 15 */ 16 17 #ifndef COMPILE_DWA20011022_H 18 #define COMPILE_DWA20011022_H 19 20 #include "config.h" 21 #include "frames.h" 22 #include "lists.h" 23 #include "object.h" 24 #include "rules.h" 25 26 void compile_builtins(); 27 28 LIST * evaluate_rule( RULE * rule, OBJECT * rulename, FRAME * ); 29 LIST * call_rule( OBJECT * rulename, FRAME * caller_frame, ... ); 30 31 /* Flags for compile_set(), etc */ 32 33 #define ASSIGN_SET 0x00 /* = assign variable */ 34 #define ASSIGN_APPEND 0x01 /* += append variable */ 35 #define ASSIGN_DEFAULT 0x02 /* set only if unset */ 36 37 /* Flags for compile_setexec() */ 38 39 #define EXEC_UPDATED 0x01 /* executes updated */ 40 #define EXEC_TOGETHER 0x02 /* executes together */ 41 #define EXEC_IGNORE 0x04 /* executes ignore */ 42 #define EXEC_QUIETLY 0x08 /* executes quietly */ 43 #define EXEC_PIECEMEAL 0x10 /* executes piecemeal */ 44 #define EXEC_EXISTING 0x20 /* executes existing */ 45 46 /* Conditions for compile_if() */ 47 48 #define EXPR_NOT 0 /* ! cond */ 49 #define EXPR_AND 1 /* cond && cond */ 50 #define EXPR_OR 2 /* cond || cond */ 51 #define EXPR_EXISTS 3 /* arg */ 52 #define EXPR_EQUALS 4 /* arg = arg */ 53 #define EXPR_NOTEQ 5 /* arg != arg */ 54 #define EXPR_LESS 6 /* arg < arg */ 55 #define EXPR_LESSEQ 7 /* arg <= arg */ 56 #define EXPR_MORE 8 /* arg > arg */ 57 #define EXPR_MOREEQ 9 /* arg >= arg */ 58 #define EXPR_IN 10 /* arg in arg */ 59 60 #endif 61