mirror of
https://github.com/johnkerl/miller.git
synced 2026-07-22 07:30:43 +00:00
put comment-stripping in the grammar so #-strings don't get borked
This commit is contained in:
parent
cb860e61e0
commit
a5ce769cf7
3 changed files with 8 additions and 1 deletions
|
|
@ -491,6 +491,8 @@ false {
|
|||
return MD_TOKEN_COMMA;
|
||||
}
|
||||
|
||||
#.*\n { }
|
||||
|
||||
[ \t\r\n] { }
|
||||
|
||||
. {
|
||||
|
|
|
|||
|
|
@ -343,7 +343,8 @@ static mapper_t* shared_parse_cli(int* pargi, int argc, char** argv,
|
|||
slls_free(expression_filenames);
|
||||
slls_free(expression_strings);
|
||||
|
||||
comment_stripped_mlr_dsl_expression = alloc_comment_strip(mlr_dsl_expression);
|
||||
//comment_stripped_mlr_dsl_expression = alloc_comment_strip(mlr_dsl_expression);
|
||||
comment_stripped_mlr_dsl_expression = mlr_strdup_or_die(mlr_dsl_expression);
|
||||
|
||||
// Linked list of mlr_dsl_ast_node_t*.
|
||||
mlr_dsl_ast_t* past = mlr_dsl_parse(comment_stripped_mlr_dsl_expression, trace_parse);
|
||||
|
|
|
|||
|
|
@ -24,6 +24,10 @@ MISC:
|
|||
* oosvar-single-for mlh
|
||||
* oosvar-single-for mld
|
||||
|
||||
* try # at grammar? try not to get strip-outs from strings.
|
||||
|
||||
* gonna wanna pass maps to funcs/subrs ...... and return them too. syntax = ? val/map type-keywords?
|
||||
|
||||
----------------------------------------------------------------
|
||||
5.0.0:
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue