ins.h

来自「开放源码的编译器open watcom 1.6.0版的源代码」· C头文件 代码 · 共 51 行

H
51
字号
#ifndef _ins_h
#define _ins_h

/* $Log:        INS.H $
Revision 1.1  92/08/20  15:50:30  Anthony_Scian
.

 * Revision 1.1  1992/08/20  17:14:07  peter
 * Initial revision
 *
 */

#include <iostream.h>
#include "basics.h"

const uint nChars = 256;
typedef uchar Char;

const uint CHAR = 0;
const uint GOTO = 1;
const uint FORK = 2;
const uint TERM = 3;
const uint CTXT = 4;

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

inline bool isMarked(Ins *i){
    return (bool) i->i.marked;
}

inline void mark(Ins *i){
    i->i.marked = true;
}

inline void unmark(Ins *i){
    i->i.marked = false;
}

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?