-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy patheval.h
65 lines (56 loc) · 1.95 KB
/
eval.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
/*
$Id: eval.h 3122 2023-09-16 10:44:56Z soci $
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#ifndef EVAL_H
#define EVAL_H
#include "attributes.h"
#include "inttypes.h"
#include "stdbool.h"
#include "oper_e.h"
struct Label;
struct Oper;
struct Obj;
struct Funcargs;
struct oper_s {
Oper_types op;
struct Obj *v1;
struct Obj *v2;
linepos_t epoint;
linepos_t epoint2;
linepos_t epoint3;
struct Obj *inplace;
};
typedef struct oper_s *oper_t;
struct values_s {
struct Obj *val;
struct linepos_s epoint;
};
struct argpos_s;
extern bool get_exp(int, argcount_t, argcount_t, linepos_t);
extern struct values_s *get_val(void);
extern struct Obj *pull_val(void);
extern argcount_t get_val_remaining(void);
extern void destroy_eval(void);
extern void init_eval(void);
extern void eval_enter(void);
extern void eval_leave(void);
extern FAST_CALL size_t get_label(const uint8_t *);
extern FAST_CALL size_t get_label2(const uint8_t *, const uint8_t *);
extern MUST_CHECK struct Obj *get_star_value(address_t, struct Obj *);
extern MUST_CHECK struct Obj *get_star(void);
extern MUST_CHECK struct Obj *get_vals_tuple(void);
extern void get_vals_funcargs(struct Funcargs *f);
extern void touch_label(struct Label *);
extern MUST_CHECK struct Obj *calc2_lxor(oper_t, bool);
#endif