This allows eg maintainer-clean to be a goal name.
Functions, eg. wildcard("*.c"). These should be defined as shell
scripts with a selection of common functions defined in stdlib.
-
-Allow "-" character in identifiers, so eg. "goal maintainer-clean" works.
(* See also "let id" in [lexer.mll]. *)
let var_regexp =
- Str.regexp "\\([a-zA-Z_][a-zA-Z0-9_]*\\)[ \t]*=[ \t]*\\(.*\\)"
+ Str.regexp "\\([a-zA-Z_][-a-zA-Z0-9_]*\\)[ \t]*=[ \t]*\\(.*\\)"
let usage =
"\
let white = [' ' '\t']+
let newline = '\r' | '\n' | "\r\n"
let comment = '#' (_#'\n')*
-let id = ['a'-'z' 'A'-'Z' '_'] ['a'-'z' 'A'-'Z' '0'-'9' '_']*
+let id = ['a'-'z' 'A'-'Z' '_'] ['a'-'z' 'A'-'Z' '0'-'9' '_' '-']*
rule read =
parse