Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Idea: StringMap - hash collision resistant, don't coerce stringified integers to integers (for json, query params, etc) #118

Open
TysonAndre opened this issue Feb 7, 2022 · 1 comment

Comments

@TysonAndre
Copy link
Owner

php > var_export(json_decode('{"0":1,"\u0000":2}', true));
N_ERROR));
array (
  0 => 1,
  '' . "\0" . '' => 2,
)
php > var_export(json_decode('{"0":1,"\u0000":2}', false, JSON_PARTIAL_OUTPUT_ON_ERROR));
NULL
php > var_export(json_last_error_msg());
'The decoded property name is invalid'

parsers such as in userland may benefit from preserving string keys, types, etc, and using less memory.

@TysonAndre
Copy link
Owner Author

Related to #47

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant