summaryrefslogtreecommitdiff
path: root/src/map/magic-interpreter-aux.h
blob: 975e5020d332aef87d20ecd555ae3863ccafb495 (plain) (blame)
1
2
3
4
5
6
7
8
#ifndef MAGIC_INTERPRETER_AUX_H_
#define MAGIC_INTERPRETER_AUX_H_

#define CHECK_TYPE(v, t) ((v)->ty == t)

#define VAR(i) ((!env->vars || env->vars[i].ty == TY_UNDEF)? env->base_env->vars[i] : env->vars[i])

#endif /* !defined(MAGIC_INTERPRETER_AUX_H_) */