44 lines
828 B
C
44 lines
828 B
C
/*
|
|
*
|
|
* Copyright 2023 Oleg Borodin <borodin@unix7.org>
|
|
*
|
|
*/
|
|
|
|
#include <string.h>
|
|
#include <stdbool.h>
|
|
#include <stdio.h>
|
|
|
|
#include <cllexer.h>
|
|
#include <clcomp.h>
|
|
#include <vmapper.h>
|
|
|
|
int main(int argc, char** argv) {
|
|
(void)argc;
|
|
(void)argv;
|
|
|
|
char* _argv[] = { argv[0], "--qwerty=12345", "--foo=bar" };
|
|
int _argc = 2;
|
|
|
|
vmapper_t vmapper;
|
|
|
|
vmapper_init(&vmapper);
|
|
|
|
clcomp_t clcomp;
|
|
|
|
clcomp_init(&clcomp, &vmapper, _argv, _argc);
|
|
|
|
clcomp_parse(&clcomp);
|
|
|
|
/*
|
|
char token[1024];
|
|
int toktype = TOKEN_NULL;
|
|
int i = 0;
|
|
while (toktype != TOKEN_ENDF) {
|
|
toktype = clcomp_gettok(&lex, token);
|
|
printf("clcomp_gettok res: %d: %d [%s]\n", i, toktype, token);
|
|
i++;
|
|
}
|
|
*/
|
|
return 0;
|
|
}
|