Commit | Line | Data |
---|---|---|
114d1c9a | 1 | /****************************************************************************** |
d44e3c4f | 2 | * Copyright (c) 2000-2016 Ericsson Telecom AB |
114d1c9a EL |
3 | * All rights reserved. This program and the accompanying materials |
4 | * are made available under the terms of the Eclipse Public License v1.0 | |
5 | * which accompanies this distribution, and is available at | |
6 | * http://www.eclipse.org/legal/epl-v10.html | |
d44e3c4f | 7 | * |
8 | * Contributors: | |
9 | * Balasko, Jeno | |
10 | * Raduly, Csaba | |
11 | * | |
114d1c9a EL |
12 | ******************************************************************************/ |
13 | module usenil_not_attr_SE { //^In TTCN-3 module `usenil_not_attr_SE':// | |
14 | ||
15 | /* | |
16 | 33.2.1 The USE-NIL ... All the other components of the sequence type, if any, | |
17 | shall have a final ATTRIBUTE or ANY-ATTRIBUTES encoding instruction, or shall be the sequence-of components | |
18 | supporting a USE-ORDER or an EMBED-VALUES encoding instruction that are also final encoding instructions on the | |
19 | sequence type. | |
20 | */ | |
21 | ||
22 | type record UN { //^In type definition// | |
23 | integer i, //^error: Component 'i' of USE-NIL not ATTRIBUTE// | |
24 | boolean b, /* only the first such error is reported */ | |
25 | charstring last optional | |
26 | } | |
27 | with { | |
28 | variant "useNil"; | |
29 | } | |
30 | ||
31 | type record UN2 { //^In type definition// | |
32 | integer i, | |
33 | boolean b, //^error: Component 'b' of USE-NIL not ATTRIBUTE// | |
34 | charstring last optional | |
35 | } | |
36 | with { | |
37 | variant "useNil"; | |
38 | variant (i) "attribute" | |
39 | } | |
40 | ||
41 | type record UN3 { //^In type definition// | |
42 | record of universal charstring aa, /* A-A is as good as ATTRIBUTE */ | |
43 | boolean b, //^error: Component 'b' of USE-NIL not ATTRIBUTE// | |
44 | charstring last optional | |
45 | } | |
46 | with { | |
47 | variant "useNil"; | |
48 | variant (aa) "anyAttributes" | |
49 | } | |
50 | ||
51 | ||
52 | ||
53 | } | |
54 | with { | |
55 | encode "XML"; | |
56 | variant "controlNamespace 'urn:a' prefix 'u'" | |
57 | } |