ETSI's Bug Tracker - Part 01: TTCN-3 Core Language
View Issue Details
0003384Part 01: TTCN-3 Core LanguageClarificationpublic16-05-2008 10:4210-12-2008 12:52
Thomas Deiß 
Ina Schieferdecker 
normalminorN/A
closedfixed 
v3.3.2 (published 2008-04) 
v4.1.1 (published 2009-06)v4.1.1 (published 2009-06) 
5.2
Nokia Siemens Networks, Thomas Deiß
0003384: Usage of declarations within component types
Clause 5.2 contains the following statement:
Definitions made in a test component type may be used only in functions, test cases and altsteps referencing that component type or a consistent test component type (see clause 6.3.3) by a runs on-clause.

This is basically a matter of interpreting the english sentence. But this could be understood that e.g. a constant declared in a component type cannot be used in another declaration of the same component type (or an extension of it). If such a strict interpretation is taken, the example below would be invalid.

module m {
  type component A {
    const integer C1 := 1;
  }
  
  type component B extends A {
    const integer C2 := 2;
    var integer ia[C1] := {C3};
    var integer i := ia[0];
    const integer C3 := C1 + C2;
  }
}

I suggest to relax the statement to
"Definitions made in a test component type may be used in the component type defintion, when extending the component type definition, and in functions, test cases and altsteps referencing that component type or a consistent test component type (see clause 6.3.3) by a runs on-clause."

No tags attached.
Issue History
16-05-2008 10:42Thomas DeißNew Issue
16-05-2008 10:42Thomas DeißStatusnew => assigned
16-05-2008 10:42Thomas DeißAssigned To => Ina Schieferdecker
16-05-2008 10:42Thomas DeißClause Reference(s) => 5.2
16-05-2008 10:42Thomas DeißSource (company - Author) => Nokia Siemens Networks, Thomas Deiß
17-08-2008 09:34Ina SchieferdeckerTarget Version => Edition 4.1.1 (not yet published)
25-11-2008 15:17Ina SchieferdeckerNote Added: 0007417
25-11-2008 15:18Ina SchieferdeckerAssigned ToIna Schieferdecker => Thomas Deiß
25-11-2008 15:18Ina SchieferdeckerResolutionopen => fixed
26-11-2008 07:58Thomas DeißNote Added: 0007432
26-11-2008 07:58Thomas DeißAssigned ToThomas Deiß => Ina Schieferdecker
10-12-2008 12:51Ina SchieferdeckerNote Added: 0007629
10-12-2008 12:51Ina SchieferdeckerStatusassigned => resolved
10-12-2008 12:51Ina SchieferdeckerFixed in Version => Edition 4.1.1 (not yet published)
10-12-2008 12:52Ina SchieferdeckerStatusresolved => closed

Notes
(0007417)
Ina Schieferdecker   
25-11-2008 15:17   
Just some rephrasing:

"Definitions made in a test component type may be used in a component type extending this component type definition, and in functions, test cases and altsteps referencing that component type or a consistent test component type (see clause 6.3.3) by a runs on-clause."

An example could be added:

  type component MyComponentType {
    const integer MyConst := 1;
    ...
  }
  
  type component MyExtendedComponentType extends MyComponentType {
    var integer MyVar:= 2 * MyConst;
    ...
  }
(0007432)
Thomas Deiß   
26-11-2008 07:58   
The example clarifies the issue, so that's also ok for me.

The solution uses 'consistent' instead of 'compatible'. There is a risk that CR 3951 is undone by this correction.
(0007629)
Ina Schieferdecker   
10-12-2008 12:51   
Reworded to "Definitions made in a test component type may be used in a component type extending this component type definition, and in functions, test cases and altsteps referencing that component type or a compatible test component type (see clause 6.3.3) by a runs on-clause."

and example added.