fix ctrl macro for ANSI C
[unix-history] / usr / src / usr.bin / window / var.h
CommitLineData
f6d12243 1/*
60de5df9
EW
2 * @(#)var.h 3.7 %G%
3 */
4
5/*
6 * Copyright (c) 1983 Regents of the University of California,
7 * All rights reserved. Redistribution permitted subject to
8 * the terms of the Berkeley Software License Agreement.
f6d12243
EW
9 */
10
11struct var {
12 struct var *r_left;
13 struct var *r_right;
14 char *r_name;
15 struct value r_val;
16};
17
bb4a0c0b
EW
18struct var *var_set1();
19struct var *var_setstr1();
20struct var *var_setnum1();
b44eb60a 21struct var **var_lookup1();
f6d12243 22
bb4a0c0b
EW
23#define var_set(n, v) var_set1(&var_head, n, v)
24#define var_setstr(n, s) var_setstr1(&var_head, n, s)
25#define var_setnum(n, i) var_setnum1(&var_head, n, i)
26#define var_unset(n) var_unset1(&var_head, n)
27#define var_lookup(n) (*var_lookup1(&var_head, n))
28#define var_walk(f, a) var_walk1(var_head, f, a)
433bd50a 29
f6d12243 30struct var *var_head; /* secret, shhh */