commit ff4b3918668cd9572e783646bb3f8db7a188a7e5
parent 4dd2e03b74a06ed433f3fe5dd5fb832a29e631ef
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date: Sun, 30 Aug 2020 22:57:02 +0200
dlang: Small cosmetic changes
Change-Id: I745de2a2f453cc8b3c3c0444bb854818f4a30c15
Diffstat:
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git a/src/kernel/dlang.c b/src/kernel/dlang.c
@@ -16,9 +16,6 @@
#define PREFIX "> "
#define NR_ARGC_MAX 5
-unsigned in_debug;
-jmp_buf dbgrecover;
-
struct args {
char *argv[NR_ARGC_MAX];
int argc;
@@ -28,11 +25,14 @@ struct args {
struct cmd {
char *name;
char *helpmsg;
- int (*eval)(const struct cmd *cmd, struct args *args);
+ int (*eval)(const struct cmd *, struct args *);
unsigned char min;
unsigned char max;
};
+unsigned in_debug;
+jmp_buf dbgrecover;
+
static const struct cmd cmds[];
static void
@@ -53,7 +53,8 @@ ready(void)
kputs(kout, PREFIX "READY\n");
}
-/* Read a value in a given base between 2 and 16 0 means default base;
+/*
+ * Read a value in a given base between 2 and 16 0 means default base;
* 10, unless the string begins with "0x" or "0b"
*/
static unsigned long long
@@ -405,28 +406,28 @@ static const struct cmd cmds[] = {
.eval = do_ls,
.min = 2,
.max = 2,
- .helpmsg = "list content of a directory: ls path",
+ .helpmsg = "List content of a directory: ls path",
},
{
.name = "cat",
.eval = do_cat,
.min = 2,
.max = 2,
- .helpmsg = "read content from a file: cat path",
+ .helpmsg = "Read content from a file: cat path",
},
{
.name = "echo",
.eval = do_echo,
.min = 3,
.max = NR_ARGC_MAX,
- .helpmsg = "write content to a file: echo path string ...",
+ .helpmsg = "Write content to a file: echo path string ...",
},
{
.name = "stat",
.eval = do_stat,
.min = 2,
.max = 2,
- .helpmsg = "display stat attribute: stat path",
+ .helpmsg = "Display stat attribute: stat path",
},
{
.name = NULL