Skip to content

Commit bd8c223

Browse files
committed
these macros don't need to be in cfg.def.h
1 parent 4e47fad commit bd8c223

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

cfg.def.h

-16
Original file line numberDiff line numberDiff line change
@@ -39,22 +39,6 @@ static struct scheme schemes[SchemeLast] = {
3939
},
4040
};
4141

42-
#define DEFCMD(b, nme, cmd) \
43-
{ .bind = (b), \
44-
.name = (nme), \
45-
.command = (cmd), \
46-
.nchildren = 0, \
47-
.children = NULL, \
48-
},
49-
50-
#define DEFPREFIX(b, nme, cs) \
51-
{ .bind = b, \
52-
.name = nme, \
53-
.command = 0, \
54-
.nchildren = LENGTH(cs), \
55-
.children = (cs), \
56-
},
57-
5842
static struct command test_commands[] = {
5943
DEFCMD("t", "test command", "echo ok")
6044
};

cmdtree.c

+16
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,22 @@ static int sep_width;
3939
static int bh, mw, mh;
4040
static XIC xic;
4141

42+
#define DEFCMD(b, nme, cmd) \
43+
{ .bind = (b), \
44+
.name = (nme), \
45+
.command = (cmd), \
46+
.nchildren = 0, \
47+
.children = NULL, \
48+
},
49+
50+
#define DEFPREFIX(b, nme, cs) \
51+
{ .bind = b, \
52+
.name = nme, \
53+
.command = 0, \
54+
.nchildren = LENGTH(cs), \
55+
.children = (cs), \
56+
},
57+
4258
#include "cfg.h"
4359

4460
static int

0 commit comments

Comments
 (0)