Skip to content

Error in decoding JSON float value starting with "-0." #9

@zxweed

Description

@zxweed

for example {"Value":-0.01000} will return 0.01. Negative sign will be lost due to code:

var C : WideChar;
    N : Boolean;
begin
..
        if N then
          Result := -Result;   // if Result=0, the minus sign will be lost
end;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions