Skip to content

Clarify the handling of +0 and -0 in keys #375

Open
@abacabadabacaba

Description

@abacabadabacaba

Currently, according to the spec, both +0 and -0 are valid keys. So, when a value is stored with the key -0, a later call to getAllKeys should return -0 as the key. However, some implementations instead are replacing -0 with +0.

Also, given that -0 == +0, an object store or a unique index can have either -0 or +0 as a key, but not both.

The value +0 or -0 can be the whole key, or a (possibly nested) array element of the key.

I think that the spec should be clarified to note the existence of equal but different keys, and to provide examples of correct behavior (e.g. put replacing an entry with a different key).

Metadata

Metadata

Assignees

No one assigned

    Labels

    TPAC2024Topic for discussion at TPAC 2024has-prhas-testsinteropBehavior difference between engines

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions