File: ins.h

package info (click to toggle)
yasm 1.3.0-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,880 kB
  • sloc: asm: 74,423; ansic: 53,055; python: 9,927; sh: 5,276; xml: 1,617; makefile: 214; pascal: 95; sed: 16
file content (40 lines) | stat: -rw-r--r-- 537 bytes parent folder | download | duplicates (17)
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
#ifndef re2c_ins_h
#define re2c_ins_h

#include "tools/re2c/basics.h"

#define nChars 256
typedef unsigned char Char;

#define CHAR 0
#define GOTO 1
#define FORK 2
#define TERM 3
#define CTXT 4

typedef union Ins {
    struct {
	byte	tag;
	byte	marked;
	void	*link;
    }			i;
    struct {
	unsigned short	value;
	unsigned short	bump;
	void	*link;
    }			c;
} Ins;

static int isMarked(Ins *i){
    return i->i.marked != 0;
}

static void mark(Ins *i){
    i->i.marked = 1;
}

static void unmark(Ins *i){
    i->i.marked = 0;
}

#endif