ETSI's Bug Tracker - Part 01: TTCN-3 Core Language
View Issue Details
0006811Part 01: TTCN-3 Core LanguageTechnicalpublic05-11-2014 14:5704-01-2015 20:11
Tomas Urban 
Gyorgy Rethy 
normalminoralways
closedfixed 
v4.6.1 (published 2014-06) 
v4.7.1 (published 2015-06)v4.7.1 (published 2015-06) 
A.1.6.1.1
STF 478
0006811: Missing BNF support for lower bound exclustion in length restriction
The BNF rule for the length restriction doesn't allow to use exclamation mark when defining the lower bound. The rule shall be changed from

44.StringLength ::= LengthKeyword "(" SingleExpression [".." Bound] ")"

to

44.StringLength ::= LengthKeyword "(" ["!"] SingleExpression [".." Bound] ")"
No tags attached.
Issue History
05-11-2014 14:57Tomas UrbanNew Issue
05-11-2014 14:57Tomas UrbanStatusnew => assigned
05-11-2014 14:57Tomas UrbanAssigned To => Gyorgy Rethy
06-11-2014 08:26Gyorgy RethyNote Added: 0012442
06-11-2014 08:27Gyorgy RethyNote Added: 0012443
06-11-2014 08:27Gyorgy RethyAssigned ToGyorgy Rethy => Tomas Urban
06-11-2014 08:27Gyorgy RethyStatusassigned => confirmed
06-11-2014 08:58Tomas UrbanNote Added: 0012445
06-11-2014 08:58Tomas UrbanAssigned ToTomas Urban => Gyorgy Rethy
06-11-2014 12:34Gyorgy RethyNote Added: 0012459
06-11-2014 12:35Gyorgy RethyNote Added: 0012460
06-11-2014 12:35Gyorgy RethyStatusconfirmed => resolved
06-11-2014 12:35Gyorgy RethyFixed in Version => v4.7.1 (published 2015-06)
06-11-2014 12:35Gyorgy RethyResolutionopen => fixed
04-01-2015 20:11Gyorgy RethyNote Added: 0012610
04-01-2015 20:11Gyorgy RethyStatusresolved => closed

Notes
(0012442)
Gyorgy Rethy   
06-11-2014 08:26   
Optional ! is added to Bound due to special values in range constraints, where they have well defined semantics (because special values have concrete encodings)

In case of length adding ! would complicate the language without obvious advantage and it would be difficult -if not impossible - to explain the semantics of ..!infinity.

Let's go the opposite way and add the static semantics rule excluding ! for length contraints:

44.StringLength ::= LengthKeyword "(" SingleExpression [".." Bound] ")"

/* STATIC SEMANTICS - StringLength shall only be used with String types or to limit set of and record of. SingleExpression and Bound shall evaluate to non-negative integer values (in case of Bound including infinity) <new> and in Bound the oprional "!" shall not be present</new>*/
(0012443)
Gyorgy Rethy   
06-11-2014 08:27   
Pleae check the proposed solution in the previous note.
(0012445)
Tomas Urban   
06-11-2014 08:58   
In principle I agree, but I think it is better to exclude the exclamation mark directly in the BNF rule than by static semantics. This way we get rid off -infinity as well:

44.StringLength ::= LengthKeyword "(" SingleExpression [".." (SingleExpression | InfinityKeyword]) ")"

/* STATIC SEMANTICS - StringLength shall only be used with String types or to limit set of and record of. SingleExpression and Bound shall evaluate to non-negative integer values */
(0012459)
Gyorgy Rethy   
06-11-2014 12:34   
Yes, I agree, much better solution...

I have chenged it in the BNF <a small change: closing ) and ] shall be swapped: InfinityKeyword)] >
(0012460)
Gyorgy Rethy   
06-11-2014 12:35   
Added to BNF in BNF tool and also to master copy.
(0012610)
Gyorgy Rethy   
04-01-2015 20:11   
Added to draft V.4.6.3