ETSI's Bug Tracker - Part 01: TTCN-3 Core Language
View Issue Details
0006646Part 01: TTCN-3 Core LanguageTechnicalpublic17-10-2013 17:2304-01-2015 21:01
Tomas Urban 
Gyorgy Rethy 
normalminorhave not tried
closedfixed 
v4.5.1 (published 2013-04) 
v4.7.1 (published 2015-06)v4.7.1 (published 2015-06) 
6.2
STF 470
0006646: Missing semantic rules for the index and assignment notation
The following rules seem to be obvious and implicitly implied, but it would be worth of considering to declare them explicitly:

1. The value used in the index notation shall be of an integer type (The specification currently only mentions numeric boundaries without formally saying anything about the type. It raises a question whether e.g. arr["0"] can be a valid statement. In some programming languages, it is a valid statement.)

2. The value used in the index notation shall not be smaller than the index of the first item. (The current rules specify precisely the lower index only, but underflow situation is not considered at all).

3. The index values used in the assignment notation for record of, set of and array values shall obey the rules valid for values used in the index notation. (Although obvious, such a rule is currently missing and it would be wise to formalize it.)

P.S. Missing rules of this kind complicate the work of STF 470, because without a formal requirement, it is difficult to link a our test cases with related clauses in the core language specification and causes troubles in tracking test coverage.
No tags attached.
related to 0006762closed Gyorgy Rethy Array indexing breaches strong typing principle 
related to 0006645closed Gyorgy Rethy Rules for array values 
doc CR6646.doc (342,016) 26-11-2013 11:15
http://oldforge.etsi.org/mantis/file_download.php?file_id=2939&type=bug
doc CR6646_v2.doc (349,184) 08-10-2014 11:24
http://oldforge.etsi.org/mantis/file_download.php?file_id=3110&type=bug
Issue History
17-10-2013 17:23Tomas UrbanNew Issue
17-10-2013 17:23Tomas UrbanClause Reference(s) => 6.2
17-10-2013 17:23Tomas UrbanSource (company - Author) => STF 470
21-11-2013 10:44Gyorgy RethyStatusnew => assigned
21-11-2013 10:44Gyorgy RethyAssigned To => Jacob Wieland - Spirent
21-11-2013 13:18Gyorgy RethyNote Added: 0011812
21-11-2013 13:18Gyorgy RethyTarget Version => v4.6.1 (published 2014-06)
26-11-2013 11:15Jacob Wieland - SpirentFile Added: CR6646.doc
26-11-2013 11:18Jacob Wieland - SpirentNote Added: 0011832
26-11-2013 11:18Jacob Wieland - SpirentAssigned ToJacob Wieland - Spirent => Gyorgy Rethy
26-11-2013 11:18Jacob Wieland - SpirentStatusassigned => confirmed
08-04-2014 16:51Gyorgy RethyTarget Versionv4.6.1 (published 2014-06) => v4.7.1 (published 2015-06)
06-10-2014 14:56Gyorgy RethyAssigned ToGyorgy Rethy => Jens Grabowski
06-10-2014 14:56Gyorgy RethyStatusconfirmed => assigned
06-10-2014 14:57Gyorgy RethyStatusassigned => confirmed
07-10-2014 16:05Jens GrabowskiAssigned ToJens Grabowski => Tomas Urban
07-10-2014 16:05Jens GrabowskiStatusconfirmed => assigned
07-10-2014 16:05Jens GrabowskiStatusassigned => confirmed
07-10-2014 16:16Tomas UrbanNote Added: 0012262
07-10-2014 16:16Tomas UrbanStatusconfirmed => resolved
07-10-2014 16:16Tomas UrbanResolutionopen => fixed
07-10-2014 16:16Tomas UrbanAssigned ToTomas Urban => Gyorgy Rethy
08-10-2014 11:24Tomas UrbanAssigned ToGyorgy Rethy => Tomas Urban
08-10-2014 11:24Tomas UrbanNote Added: 0012276
08-10-2014 11:24Tomas UrbanStatusresolved => feedback
08-10-2014 11:24Tomas UrbanResolutionfixed => reopened
08-10-2014 11:24Tomas UrbanFile Added: CR6646_v2.doc
08-10-2014 11:25Tomas UrbanRelationship addedrelated to 0006762
08-10-2014 11:29Tomas UrbanNote Added: 0012277
08-10-2014 11:29Tomas UrbanStatusfeedback => assigned
08-10-2014 11:29Tomas UrbanAssigned ToTomas Urban => Jens Grabowski
08-10-2014 11:29Tomas UrbanStatusassigned => confirmed
08-10-2014 14:41Jens GrabowskiStatusconfirmed => resolved
08-10-2014 14:41Jens GrabowskiResolutionreopened => fixed
08-10-2014 14:41Jens GrabowskiAssigned ToJens Grabowski => Gyorgy Rethy
05-11-2014 09:46Tomas UrbanRelationship addedrelated to 0006645
04-01-2015 21:01Gyorgy RethyNote Added: 0012614
04-01-2015 21:01Gyorgy RethyStatusresolved => closed
04-01-2015 21:01Gyorgy RethyFixed in Version => v4.7.1 (published 2015-06)

Notes
(0011812)
Gyorgy Rethy   
21-11-2013 13:18   
Jacob, pls. check in the standard's text what rules are missing for the index notation. All rules could be listed in clause 6.2.3, to make it easier for the reader (and also for us to notice if something is missing).

Other:
- "indexed notation" should be changed to "index notation": clause 6.2, 6.2.3 (2*), 6.2.7
- "Indexed value notation" be changed to index notation too: clause 6.2.3, 6.2.7
(0011832)
Jacob Wieland - Spirent   
26-11-2013 11:18   
I have put/refined the explanation regarding the index in the index notation definition. 6.2.3 only treats record of an set of while index notation is also for arrays and string types (with the same restrictions).

Also changed all references to the notation to "index notation"
(0012262)
Tomas Urban   
07-10-2014 16:16   
The proposed resolution solves the issues described in this CR and can be added into next version of the TTCN-3 core language standard.
(0012276)
Tomas Urban   
08-10-2014 11:24   
Reopened because of use of the forbidden word "must" and missing reference to array and record of values used as an index in the index notation definition.
(0012277)
Tomas Urban   
08-10-2014 11:29   
When I was updating 0006762 I noticed that some facts were missing in the indexing value definition. I modified the definition adding the missing features.
Please check.
(0012614)
Gyorgy Rethy   
04-01-2015 21:01   
Added to draft V4.6.3