ETSI's Bug Tracker - Part 01: TTCN-3 Core Language
View Issue Details

ID | Project | Category | View Status | Date Submitted | Last Update
0006008 | Part 01: TTCN-3 Core Language | Clarification | public | 19-01-2012 17:18 | 10-07-2012 13:59

Reporter | Nikolay Pakulin |
Assigned To |  |
Priority | normal | Severity | minor | Reproducibility | N/A
Status | closed | Resolution | won't fix |
Platform |  | OS |  | OS Version |
Product Version | v4.3.1 (published 2011-06) |
Target Version | v4.5.1 (published 2013-04) | Fixed in Version |  |
Clause Reference(s) | B 1.1, 6.3
Source (company - Author) | ISPRAS, STF 433

Summary | 0006008: Match omit Ð¼Ñ‹ undefined value

Description

The following test case is a refined case when a record, initialized by an array, is matched back agains that array. The pecularity of the test case is that the array contains an undefined element. According to clause 6.3.2.2 corresponding optional field of the record becomes *omit*.
So, the question actually is: how to match an omitted value against an undefined value. What output should the test case produce -- whether full values match or not, whether omitted value matched undefined?

Steps To Reproduce |

Additional Information

module match_omit_undefined {
type record Record {
integer a optional
}
type record length(1) of integer Array;
type component MTC {}
testcase TC_match_omit_undefined() runs on MTC
{
var Array array := {-};
// recrd.a must be set to omit
// TTCN3, v.4.3.1
// Clause 6.3.2.2: If an element with an undefined value is assigned to an optional element of the record, this will
// cause the optional element to be omitted.
var Record recrd := array;
var boolean v_match_structured_values := match(recrd, array);
var boolean v_match_omit_undefined := match(recrd.a, array[0]);
log("Result of matching missing elements: ", v_match_omit_undefined);
log("Result of matching structured values: ", v_match_structured_values);
}
control {
execute(TC_match_omit_undefined())
}
}

Tags | No tags attached.

Relationships

related to | 0006165 | closed |  | Add recof2setof predefined function

Attached Files |

Issue History
Date Modified | Username | Field | Change
19-01-2012 17:18 | Nikolay Pakulin | New Issue |
19-01-2012 17:18 | Nikolay Pakulin | Clause Reference(s) | => B 1.1, 6.3
19-01-2012 17:18 | Nikolay Pakulin | Source (company - Author) | => ISPRAS, STF 433
19-01-2012 17:21 | Nikolay Pakulin | Note Added: 0010546 |
10-07-2012 09:32 | Ina Schieferdecker | Relationship added | related to 0006165
10-07-2012 13:59 | Gyorgy Rethy | Note Added: 0010754 |
10-07-2012 13:59 | Gyorgy Rethy | Status | new => closed
10-07-2012 13:59 | Gyorgy Rethy | Resolution | open => won't fix
10-07-2012 13:59 | Gyorgy Rethy | Target Version | => Edition 4.5.1

Notes

(0010546)
Nikolay Pakulin
19-01-2012 17:21

The title of the CR should read: "Match omit vs undefined value". Cyrillic "Ð¼Ñ‹" crawled in due to automatic keyboard layout switcher.

(0010754)
Gyorgy Rethy
10-07-2012 13:59

There is no statement that undefined content is changed to omit. According to clause 11.1 restriction d) and e) the assignment recrd := array and both match operations above shall cause an error.