include/parser.h

changeset 5
f878a9ffa3e0
parent 4
ee28b655297b
child 6
f73065173121
--- a/include/parser.h	Wed Apr 19 22:03:51 2000 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,45 +0,0 @@
-/*
- * libtu/parser.h
- *
- * Copyright (c) Tuomo Valkonen 1999-2000.
- * 
- * This file is distributed under the terms of the "Artistic License".
- * See the included file LICENSE for details.
- */
-
-#ifndef __LIBTU_PARSER_H
-#define __LIBTU_PARSER_H
-
-#include "tokenizer.h"
-
-/*
- * format:
- * 	l = long
- *	d = double
- * 	i = identifier
- * 	s = string
- * 	c = char
- *  . = 1 times any     ("l.d")
- *  * = 0 or more times any (must be the last, "sd*")
- * 	? = optional		("?c")
- * 	: = conditional		(":c:s")
- *  + = 1 or more times last (most be the last, "l+")
- * special entries:
- * 
- * "#end" 		call this handler at the end of section.
- * "#cancel" 	call this handler when recovering from error
- */
-
-typedef struct _ConfOpt{
-	const char *optname;
-	const char *argfmt;
-	bool (*fn)(Tokenizer *tokz, int n, Token *toks);
-	struct _ConfOpt *opts;
-} ConfOpt;
-
-
-extern bool parse_config_tokz(Tokenizer *tokz, const ConfOpt *options);
-extern bool parse_config(const char *fname, const ConfOpt *options, int flags);
-extern bool parse_config_file(FILE *file, const ConfOpt *options, int flags);
-
-#endif /* __LIBTU_PARSER_H */

mercurial