/ Check-in [508b20f070]
DEMO | DOWNLOAD | DEPLOY | SEARCH
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Object key now accepts undef.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:508b20f070988a8e011be99679956ccf877d24b9
User & Date: pmacdona 2019-04-27 19:52:37
Context
2019-04-28
15:19
Add cdata map demo check-in: ee01fbb629 user: pmacdona tags: trunk
2019-04-27
19:52
Object key now accepts undef. check-in: 508b20f070 user: pmacdona tags: trunk
19:19
Release "2.8.24". Map now accepts non-string keys: number, bool and null. check-in: d30f6bb2d4 user: pmacdona tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/parser.y.

776
777
778
779
780
781
782

783
784
785
786
787
788
789
790
791
792
793

item:
    IDENTIFIER ':' expr { $$ = codes_join(code_push_string(pstate,&@1, $1), $3); }
    | STRING ':' expr   { $$ = codes_join(code_push_string(pstate,&@1, $1), $3); }
    | FNUMBER ':' expr { $$ = codes_join(code_push_num($1), $3);  }
    | _TRUE ':' expr { $$ = codes_join(code_push_bool(1), $3);  }
    | _FALSE ':' expr { $$ = codes_join(code_push_bool(0), $3);  }

    | TYPENULL ':' expr { $$ = codes_join(code_push_null(), $3);  }
;

array:
    '[' exprlist ']' { $$ = codes_join($2, code_array(pstate, &@2, ($2)->expr_counter)); }
    | '[' ']' { $$ = code_array(pstate, &@1, 0); }
;


%%








>











776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794

item:
    IDENTIFIER ':' expr { $$ = codes_join(code_push_string(pstate,&@1, $1), $3); }
    | STRING ':' expr   { $$ = codes_join(code_push_string(pstate,&@1, $1), $3); }
    | FNUMBER ':' expr { $$ = codes_join(code_push_num($1), $3);  }
    | _TRUE ':' expr { $$ = codes_join(code_push_bool(1), $3);  }
    | _FALSE ':' expr { $$ = codes_join(code_push_bool(0), $3);  }
    | UNDEF ':' expr { $$ = codes_join(code_push_undef(), $3);  }
    | TYPENULL ':' expr { $$ = codes_join(code_push_null(), $3);  }
;

array:
    '[' exprlist ']' { $$ = codes_join($2, code_array(pstate, &@2, ($2)->expr_counter)); }
    | '[' ']' { $$ = code_array(pstate, &@1, 0); }
;


%%