Logo etsi

ETSI's Bug Tracker

Notice: information submitted on the ETSI issue Tracker may be incorporated in ETSI publication(s) and therefore subject to the ETSI IPR policy.

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0007725Part 11: Using JSON with TTCN-3[TTCN-3 Change Requests] Clarificationpublic25-10-2017 12:0005-01-2018 09:19
Reporternikolajev 
Assigned ToGyorgy Rethy 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusclosedResolutionfixed 
PlatformOSOS Version
Product VersionV4.7.1 (published 2017-06) 
Target VersionV4.8.1 (published 2020-05)Fixed in VersionV4.8.1 (published 2020-05) 
Summary0007725: "Part 11: Using JSON with TTCN-3":"B.3.6 Use the Minus sign" assumptions for TTCN-3 Core Language spec
Description"B.3.6 Use the Minus sign" makes the assumption that TTCN-3 Core Language specification distinguishes signed +0/-0 integers and +0.0/-0.0 float values.

In TTCN-3 Core Language specification "6.1.0 Simple basic types and values", under:
 "a) integer: ..." it is stated that "the value zero shall be represented by a single zero" without specifying that it must be signed.

float type description does not indicate any requirements for signed 0.0 value.
TagsNo tags attached.
Attached Filesdocx file icon CR7725.docx [^] (144,285 bytes) 26-10-2017 10:14
docx file icon CR7725-v2.docx [^] (162,983 bytes) 26-10-2017 13:38

- Relationships

-  Notes
(0014879)
Kristóf Szabados (reporter)
26-10-2017 09:53

For float values the core standard allows the mantissa to be a negative integer.

C.1.29 also gives an example:
"str2float("-0.0") // returns a float value equal to -0.0"

In section 7.1.3 Relational Operators states
"Two floating-point numbers are equal if and only if they contain the same value. The values minus zero and
plus zero are two distinct values (e.g. they are encoded differently in some standardized languages) and minus
zero is less than plus zero, which represents zero."
(0014880)
Kristóf Szabados (reporter)
26-10-2017 09:56

Section B.3.6 (Use the Minus sign) describes how to decode the different zero kinds by default and using the "useMinus" encoding instruction.

But this part also describes that the -0 JSON value to be decoded as a negative 0 in TTCN-3.

during STF discussion we decided to change this so that the -0 JSON value is decoded into the -0.0 TTCN-3 value.
(0014891)
Tomas Urban (developer)
26-10-2017 13:41

I made some additional changes to the text:
1. Minus sign is always discarded during decoding of integer types
2. The user has an option to use a float-point type instead (there's a note about that)
3. The "useMinus" instruction is available for a float-point type values only.
(0014914)
Kristóf Szabados (reporter)
27-10-2017 12:40

looks good to me.
(0014999)
Gyorgy Rethy (reporter)
05-01-2018 09:19

Implemented with slight modification: first sentence in B.3.6 is clarified;
old text: "By default, TTCN-3 values of JSON.Number and JSON.Integer and IEEE 754 float useful types are decoded by their values, i.e. ..." (but in fact JSON values are decoded TO JSON.Number ... types).
new text: "By default, without the “useMinus” instruction, JSON numbers are decoded to TTCN-3 JSON.Number and IEEE 754 float useful types by their values; i.e. ..."

- Issue History
Date Modified Username Field Change
25-10-2017 12:00 nikolajev New Issue
26-10-2017 09:53 Kristóf Szabados Note Added: 0014879
26-10-2017 09:53 Kristóf Szabados Assigned To => Kristóf Szabados
26-10-2017 09:53 Kristóf Szabados Status new => assigned
26-10-2017 09:56 Kristóf Szabados Note Added: 0014880
26-10-2017 10:02 Kristóf Szabados Status assigned => confirmed
26-10-2017 10:14 Kristóf Szabados File Added: CR7725.docx
26-10-2017 10:18 Kristóf Szabados Assigned To Kristóf Szabados => Tomas Urban
26-10-2017 10:18 Kristóf Szabados Status confirmed => assigned
26-10-2017 10:18 Kristóf Szabados Status assigned => confirmed
26-10-2017 13:38 Tomas Urban File Added: CR7725-v2.docx
26-10-2017 13:41 Tomas Urban Note Added: 0014891
26-10-2017 13:41 Tomas Urban Assigned To Tomas Urban => Kristóf Szabados
27-10-2017 12:40 Kristóf Szabados Note Added: 0014914
27-10-2017 12:40 Kristóf Szabados Status confirmed => resolved
27-10-2017 12:40 Kristóf Szabados Resolution open => fixed
27-10-2017 12:40 Kristóf Szabados Assigned To Kristóf Szabados => Gyorgy Rethy
04-01-2018 17:01 Gyorgy Rethy Project TTCN-3 Change Requests => Part 11: Using JSON with TTCN-3
05-01-2018 09:19 Gyorgy Rethy Note Added: 0014999
05-01-2018 09:19 Gyorgy Rethy Status resolved => closed
05-01-2018 09:19 Gyorgy Rethy Product Version => V4.7.1 (published 2017-06)
05-01-2018 09:19 Gyorgy Rethy Fixed in Version => V4.8.1 (published 2020-05)
05-01-2018 09:19 Gyorgy Rethy Target Version => V4.8.1 (published 2020-05)


MantisBT 1.2.14 [^]
Copyright © 2000 - 2024 MantisBT Team
Powered by Mantis Bugtracker