pidl: fix formatting in idl.yp
[Samba/aatanasov.git] / pidl / lib / Parse / Pidl / IDL.pm
blob53be9fc65514da405e19501680dcb31c3ca6a183
1 ####################################################################
3 # This file was generated using Parse::Yapp version 1.05.
5 # Don't edit this file, use source file instead.
7 # ANY CHANGE MADE HERE WILL BE LOST !
9 ####################################################################
10 package Parse::Pidl::IDL;
11 use vars qw ( @ISA );
12 use strict;
14 @ISA= qw ( Parse::Yapp::Driver );
15 use Parse::Yapp::Driver;
19 sub new {
20 my($class)=shift;
21 ref($class)
22 and $class=ref($class);
24 my($self)=$class->SUPER::new( yyversion => '1.05',
25 yystates =>
27 {#State 0
28 DEFAULT => -1,
29 GOTOS => {
30 'idl' => 1
33 {#State 1
34 ACTIONS => {
35 '' => 2,
36 "cpp_quote" => 3,
37 "importlib" => 4,
38 "import" => 7,
39 "include" => 13
41 DEFAULT => -87,
42 GOTOS => {
43 'cpp_quote' => 11,
44 'importlib' => 10,
45 'interface' => 9,
46 'include' => 5,
47 'coclass' => 12,
48 'import' => 8,
49 'property_list' => 6
52 {#State 2
53 DEFAULT => 0
55 {#State 3
56 ACTIONS => {
57 "(" => 14
60 {#State 4
61 ACTIONS => {
62 'TEXT' => 16
64 GOTOS => {
65 'commalist' => 15,
66 'text' => 17
69 {#State 5
70 DEFAULT => -5
72 {#State 6
73 ACTIONS => {
74 "coclass" => 18,
75 "[" => 20,
76 "interface" => 19
79 {#State 7
80 ACTIONS => {
81 'TEXT' => 16
83 GOTOS => {
84 'commalist' => 21,
85 'text' => 17
88 {#State 8
89 DEFAULT => -4
91 {#State 9
92 DEFAULT => -2
94 {#State 10
95 DEFAULT => -6
97 {#State 11
98 DEFAULT => -7
100 {#State 12
101 DEFAULT => -3
103 {#State 13
104 ACTIONS => {
105 'TEXT' => 16
107 GOTOS => {
108 'commalist' => 22,
109 'text' => 17
112 {#State 14
113 ACTIONS => {
114 'TEXT' => 16
116 GOTOS => {
117 'text' => 23
120 {#State 15
121 ACTIONS => {
122 ";" => 24,
123 "," => 25
126 {#State 16
127 DEFAULT => -118
129 {#State 17
130 DEFAULT => -11
132 {#State 18
133 ACTIONS => {
134 'IDENTIFIER' => 26
136 GOTOS => {
137 'identifier' => 27
140 {#State 19
141 ACTIONS => {
142 'IDENTIFIER' => 26
144 GOTOS => {
145 'identifier' => 28
148 {#State 20
149 ACTIONS => {
150 'IDENTIFIER' => 26
152 GOTOS => {
153 'identifier' => 30,
154 'property' => 31,
155 'properties' => 29
158 {#State 21
159 ACTIONS => {
160 ";" => 32,
161 "," => 25
164 {#State 22
165 ACTIONS => {
166 ";" => 33,
167 "," => 25
170 {#State 23
171 ACTIONS => {
172 ")" => 34
175 {#State 24
176 DEFAULT => -10
178 {#State 25
179 ACTIONS => {
180 'TEXT' => 16
182 GOTOS => {
183 'text' => 35
186 {#State 26
187 DEFAULT => -114
189 {#State 27
190 ACTIONS => {
191 "{" => 36
194 {#State 28
195 ACTIONS => {
196 ":" => 37
198 DEFAULT => -17,
199 GOTOS => {
200 'base_interface' => 38
203 {#State 29
204 ACTIONS => {
205 "," => 39,
206 "]" => 40
209 {#State 30
210 ACTIONS => {
211 "(" => 41
213 DEFAULT => -91
215 {#State 31
216 DEFAULT => -89
218 {#State 32
219 DEFAULT => -8
221 {#State 33
222 DEFAULT => -9
224 {#State 34
225 DEFAULT => -19
227 {#State 35
228 DEFAULT => -12
230 {#State 36
231 DEFAULT => -14,
232 GOTOS => {
233 'interface_names' => 42
236 {#State 37
237 ACTIONS => {
238 'IDENTIFIER' => 26
240 GOTOS => {
241 'identifier' => 43
244 {#State 38
245 ACTIONS => {
246 "{" => 44
249 {#State 39
250 ACTIONS => {
251 'IDENTIFIER' => 26
253 GOTOS => {
254 'identifier' => 30,
255 'property' => 45
258 {#State 40
259 DEFAULT => -88
261 {#State 41
262 ACTIONS => {
263 'CONSTANT' => 48,
264 'TEXT' => 16,
265 'IDENTIFIER' => 26
267 DEFAULT => -95,
268 GOTOS => {
269 'identifier' => 50,
270 'text' => 51,
271 'anytext' => 46,
272 'constant' => 47,
273 'commalisttext' => 49
276 {#State 42
277 ACTIONS => {
278 "}" => 52,
279 "interface" => 53
282 {#State 43
283 DEFAULT => -18
285 {#State 44
286 ACTIONS => {
287 "const" => 63
289 DEFAULT => -87,
290 GOTOS => {
291 'typedecl' => 54,
292 'function' => 55,
293 'definitions' => 57,
294 'bitmap' => 56,
295 'definition' => 60,
296 'property_list' => 59,
297 'usertype' => 58,
298 'const' => 62,
299 'struct' => 61,
300 'typedef' => 65,
301 'enum' => 64,
302 'union' => 66
305 {#State 45
306 DEFAULT => -90
308 {#State 46
309 ACTIONS => {
310 "-" => 68,
311 ":" => 67,
312 "<" => 70,
313 "+" => 72,
314 "~" => 71,
315 "*" => 79,
316 "?" => 69,
317 "{" => 73,
318 "&" => 74,
319 "/" => 75,
320 "=" => 76,
321 "(" => 77,
322 "|" => 78,
323 "." => 80,
324 ">" => 81
326 DEFAULT => -93
328 {#State 47
329 DEFAULT => -97
331 {#State 48
332 DEFAULT => -117
334 {#State 49
335 ACTIONS => {
336 "," => 82,
337 ")" => 83
340 {#State 50
341 DEFAULT => -96
343 {#State 51
344 DEFAULT => -98
346 {#State 52
347 ACTIONS => {
348 ";" => 85
350 DEFAULT => -119,
351 GOTOS => {
352 'optional_semicolon' => 84
355 {#State 53
356 ACTIONS => {
357 'IDENTIFIER' => 26
359 GOTOS => {
360 'identifier' => 86
363 {#State 54
364 DEFAULT => -25
366 {#State 55
367 DEFAULT => -22
369 {#State 56
370 DEFAULT => -33
372 {#State 57
373 ACTIONS => {
374 "}" => 87,
375 "const" => 63
377 DEFAULT => -87,
378 GOTOS => {
379 'typedecl' => 54,
380 'function' => 55,
381 'bitmap' => 56,
382 'definition' => 88,
383 'property_list' => 59,
384 'usertype' => 58,
385 'struct' => 61,
386 'const' => 62,
387 'typedef' => 65,
388 'enum' => 64,
389 'union' => 66
392 {#State 58
393 ACTIONS => {
394 ";" => 89
397 {#State 59
398 ACTIONS => {
399 "typedef" => 90,
400 'IDENTIFIER' => 26,
401 "signed" => 98,
402 "union" => 91,
403 "enum" => 100,
404 "bitmap" => 101,
405 'void' => 92,
406 "unsigned" => 102,
407 "[" => 20,
408 "struct" => 97
410 GOTOS => {
411 'existingtype' => 99,
412 'bitmap' => 56,
413 'usertype' => 94,
414 'property_list' => 93,
415 'identifier' => 95,
416 'struct' => 61,
417 'enum' => 64,
418 'type' => 103,
419 'union' => 66,
420 'sign' => 96
423 {#State 60
424 DEFAULT => -20
426 {#State 61
427 DEFAULT => -30
429 {#State 62
430 DEFAULT => -23
432 {#State 63
433 ACTIONS => {
434 'IDENTIFIER' => 26
436 GOTOS => {
437 'identifier' => 104
440 {#State 64
441 DEFAULT => -32
443 {#State 65
444 DEFAULT => -24
446 {#State 66
447 DEFAULT => -31
449 {#State 67
450 ACTIONS => {
451 'CONSTANT' => 48,
452 'TEXT' => 16,
453 'IDENTIFIER' => 26
455 DEFAULT => -95,
456 GOTOS => {
457 'identifier' => 50,
458 'anytext' => 105,
459 'text' => 51,
460 'constant' => 47
463 {#State 68
464 ACTIONS => {
465 'CONSTANT' => 48,
466 'TEXT' => 16,
467 'IDENTIFIER' => 26
469 DEFAULT => -95,
470 GOTOS => {
471 'identifier' => 50,
472 'anytext' => 106,
473 'text' => 51,
474 'constant' => 47
477 {#State 69
478 ACTIONS => {
479 'CONSTANT' => 48,
480 'TEXT' => 16,
481 'IDENTIFIER' => 26
483 DEFAULT => -95,
484 GOTOS => {
485 'identifier' => 50,
486 'anytext' => 107,
487 'text' => 51,
488 'constant' => 47
491 {#State 70
492 ACTIONS => {
493 'CONSTANT' => 48,
494 'TEXT' => 16,
495 'IDENTIFIER' => 26
497 DEFAULT => -95,
498 GOTOS => {
499 'identifier' => 50,
500 'anytext' => 108,
501 'text' => 51,
502 'constant' => 47
505 {#State 71
506 ACTIONS => {
507 'CONSTANT' => 48,
508 'TEXT' => 16,
509 'IDENTIFIER' => 26
511 DEFAULT => -95,
512 GOTOS => {
513 'identifier' => 50,
514 'anytext' => 109,
515 'text' => 51,
516 'constant' => 47
519 {#State 72
520 ACTIONS => {
521 'CONSTANT' => 48,
522 'TEXT' => 16,
523 'IDENTIFIER' => 26
525 DEFAULT => -95,
526 GOTOS => {
527 'identifier' => 50,
528 'anytext' => 110,
529 'text' => 51,
530 'constant' => 47
533 {#State 73
534 ACTIONS => {
535 'CONSTANT' => 48,
536 'TEXT' => 16,
537 'IDENTIFIER' => 26
539 DEFAULT => -95,
540 GOTOS => {
541 'identifier' => 50,
542 'anytext' => 46,
543 'text' => 51,
544 'constant' => 47,
545 'commalisttext' => 111
548 {#State 74
549 ACTIONS => {
550 'CONSTANT' => 48,
551 'TEXT' => 16,
552 'IDENTIFIER' => 26
554 DEFAULT => -95,
555 GOTOS => {
556 'identifier' => 50,
557 'anytext' => 112,
558 'text' => 51,
559 'constant' => 47
562 {#State 75
563 ACTIONS => {
564 'CONSTANT' => 48,
565 'TEXT' => 16,
566 'IDENTIFIER' => 26
568 DEFAULT => -95,
569 GOTOS => {
570 'identifier' => 50,
571 'anytext' => 113,
572 'text' => 51,
573 'constant' => 47
576 {#State 76
577 ACTIONS => {
578 'CONSTANT' => 48,
579 'TEXT' => 16,
580 'IDENTIFIER' => 26
582 DEFAULT => -95,
583 GOTOS => {
584 'identifier' => 50,
585 'anytext' => 114,
586 'text' => 51,
587 'constant' => 47
590 {#State 77
591 ACTIONS => {
592 'CONSTANT' => 48,
593 'TEXT' => 16,
594 'IDENTIFIER' => 26
596 DEFAULT => -95,
597 GOTOS => {
598 'identifier' => 50,
599 'anytext' => 46,
600 'text' => 51,
601 'constant' => 47,
602 'commalisttext' => 115
605 {#State 78
606 ACTIONS => {
607 'CONSTANT' => 48,
608 'TEXT' => 16,
609 'IDENTIFIER' => 26
611 DEFAULT => -95,
612 GOTOS => {
613 'identifier' => 50,
614 'anytext' => 116,
615 'text' => 51,
616 'constant' => 47
619 {#State 79
620 ACTIONS => {
621 'CONSTANT' => 48,
622 'TEXT' => 16,
623 'IDENTIFIER' => 26
625 DEFAULT => -95,
626 GOTOS => {
627 'identifier' => 50,
628 'anytext' => 117,
629 'text' => 51,
630 'constant' => 47
633 {#State 80
634 ACTIONS => {
635 'CONSTANT' => 48,
636 'TEXT' => 16,
637 'IDENTIFIER' => 26
639 DEFAULT => -95,
640 GOTOS => {
641 'identifier' => 50,
642 'anytext' => 118,
643 'text' => 51,
644 'constant' => 47
647 {#State 81
648 ACTIONS => {
649 'CONSTANT' => 48,
650 'TEXT' => 16,
651 'IDENTIFIER' => 26
653 DEFAULT => -95,
654 GOTOS => {
655 'identifier' => 50,
656 'anytext' => 119,
657 'text' => 51,
658 'constant' => 47
661 {#State 82
662 ACTIONS => {
663 'CONSTANT' => 48,
664 'TEXT' => 16,
665 'IDENTIFIER' => 26
667 DEFAULT => -95,
668 GOTOS => {
669 'identifier' => 50,
670 'anytext' => 120,
671 'text' => 51,
672 'constant' => 47
675 {#State 83
676 DEFAULT => -92
678 {#State 84
679 DEFAULT => -13
681 {#State 85
682 DEFAULT => -120
684 {#State 86
685 ACTIONS => {
686 ";" => 121
689 {#State 87
690 ACTIONS => {
691 ";" => 85
693 DEFAULT => -119,
694 GOTOS => {
695 'optional_semicolon' => 122
698 {#State 88
699 DEFAULT => -21
701 {#State 89
702 DEFAULT => -34
704 {#State 90
705 ACTIONS => {
706 'IDENTIFIER' => 26,
707 "signed" => 98,
708 'void' => 92,
709 "unsigned" => 102
711 DEFAULT => -87,
712 GOTOS => {
713 'existingtype' => 99,
714 'bitmap' => 56,
715 'usertype' => 94,
716 'property_list' => 93,
717 'identifier' => 95,
718 'struct' => 61,
719 'enum' => 64,
720 'type' => 123,
721 'union' => 66,
722 'sign' => 96
725 {#State 91
726 ACTIONS => {
727 'IDENTIFIER' => 124
729 DEFAULT => -115,
730 GOTOS => {
731 'optional_identifier' => 125
734 {#State 92
735 DEFAULT => -41
737 {#State 93
738 ACTIONS => {
739 "union" => 91,
740 "enum" => 100,
741 "bitmap" => 101,
742 "[" => 20,
743 "struct" => 97
746 {#State 94
747 DEFAULT => -39
749 {#State 95
750 DEFAULT => -38
752 {#State 96
753 ACTIONS => {
754 'IDENTIFIER' => 26
756 GOTOS => {
757 'identifier' => 126
760 {#State 97
761 ACTIONS => {
762 'IDENTIFIER' => 124
764 DEFAULT => -115,
765 GOTOS => {
766 'optional_identifier' => 127
769 {#State 98
770 DEFAULT => -35
772 {#State 99
773 DEFAULT => -40
775 {#State 100
776 ACTIONS => {
777 'IDENTIFIER' => 124
779 DEFAULT => -115,
780 GOTOS => {
781 'optional_identifier' => 128
784 {#State 101
785 ACTIONS => {
786 'IDENTIFIER' => 124
788 DEFAULT => -115,
789 GOTOS => {
790 'optional_identifier' => 129
793 {#State 102
794 DEFAULT => -36
796 {#State 103
797 ACTIONS => {
798 'IDENTIFIER' => 26
800 GOTOS => {
801 'identifier' => 130
804 {#State 104
805 DEFAULT => -74,
806 GOTOS => {
807 'pointers' => 131
810 {#State 105
811 ACTIONS => {
812 "-" => 68,
813 ":" => 67,
814 "<" => 70,
815 "+" => 72,
816 "~" => 71,
817 "*" => 79,
818 "?" => 69,
819 "{" => 73,
820 "&" => 74,
821 "/" => 75,
822 "=" => 76,
823 "(" => 77,
824 "|" => 78,
825 "." => 80,
826 ">" => 81
828 DEFAULT => -108
830 {#State 106
831 ACTIONS => {
832 ":" => 67,
833 "<" => 70,
834 "~" => 71,
835 "?" => 69,
836 "{" => 73,
837 "=" => 76
839 DEFAULT => -99
841 {#State 107
842 ACTIONS => {
843 "-" => 68,
844 ":" => 67,
845 "<" => 70,
846 "+" => 72,
847 "~" => 71,
848 "*" => 79,
849 "?" => 69,
850 "{" => 73,
851 "&" => 74,
852 "/" => 75,
853 "=" => 76,
854 "(" => 77,
855 "|" => 78,
856 "." => 80,
857 ">" => 81
859 DEFAULT => -107
861 {#State 108
862 ACTIONS => {
863 "-" => 68,
864 ":" => 67,
865 "<" => 70,
866 "+" => 72,
867 "~" => 71,
868 "*" => 79,
869 "?" => 69,
870 "{" => 73,
871 "&" => 74,
872 "/" => 75,
873 "=" => 76,
874 "(" => 77,
875 "|" => 78,
876 "." => 80,
877 ">" => 81
879 DEFAULT => -103
881 {#State 109
882 ACTIONS => {
883 "-" => 68,
884 ":" => 67,
885 "<" => 70,
886 "+" => 72,
887 "~" => 71,
888 "*" => 79,
889 "?" => 69,
890 "{" => 73,
891 "&" => 74,
892 "/" => 75,
893 "=" => 76,
894 "(" => 77,
895 "|" => 78,
896 "." => 80,
897 ">" => 81
899 DEFAULT => -111
901 {#State 110
902 ACTIONS => {
903 ":" => 67,
904 "<" => 70,
905 "~" => 71,
906 "?" => 69,
907 "{" => 73,
908 "=" => 76
910 DEFAULT => -110
912 {#State 111
913 ACTIONS => {
914 "}" => 132,
915 "," => 82
918 {#State 112
919 ACTIONS => {
920 ":" => 67,
921 "<" => 70,
922 "~" => 71,
923 "?" => 69,
924 "{" => 73,
925 "=" => 76
927 DEFAULT => -105
929 {#State 113
930 ACTIONS => {
931 ":" => 67,
932 "<" => 70,
933 "~" => 71,
934 "?" => 69,
935 "{" => 73,
936 "=" => 76
938 DEFAULT => -106
940 {#State 114
941 ACTIONS => {
942 "-" => 68,
943 ":" => 67,
944 "<" => 70,
945 "+" => 72,
946 "~" => 71,
947 "*" => 79,
948 "?" => 69,
949 "{" => 73,
950 "&" => 74,
951 "/" => 75,
952 "=" => 76,
953 "(" => 77,
954 "|" => 78,
955 "." => 80,
956 ">" => 81
958 DEFAULT => -109
960 {#State 115
961 ACTIONS => {
962 "," => 82,
963 ")" => 133
966 {#State 116
967 ACTIONS => {
968 ":" => 67,
969 "<" => 70,
970 "~" => 71,
971 "?" => 69,
972 "{" => 73,
973 "=" => 76
975 DEFAULT => -104
977 {#State 117
978 ACTIONS => {
979 ":" => 67,
980 "<" => 70,
981 "~" => 71,
982 "?" => 69,
983 "{" => 73,
984 "=" => 76
986 DEFAULT => -101
988 {#State 118
989 ACTIONS => {
990 ":" => 67,
991 "<" => 70,
992 "~" => 71,
993 "?" => 69,
994 "{" => 73,
995 "=" => 76
997 DEFAULT => -100
999 {#State 119
1000 ACTIONS => {
1001 ":" => 67,
1002 "<" => 70,
1003 "~" => 71,
1004 "?" => 69,
1005 "{" => 73,
1006 "=" => 76
1008 DEFAULT => -102
1010 {#State 120
1011 ACTIONS => {
1012 "-" => 68,
1013 ":" => 67,
1014 "<" => 70,
1015 "+" => 72,
1016 "~" => 71,
1017 "*" => 79,
1018 "?" => 69,
1019 "{" => 73,
1020 "&" => 74,
1021 "/" => 75,
1022 "=" => 76,
1023 "(" => 77,
1024 "|" => 78,
1025 "." => 80,
1026 ">" => 81
1028 DEFAULT => -94
1030 {#State 121
1031 DEFAULT => -15
1033 {#State 122
1034 DEFAULT => -16
1036 {#State 123
1037 ACTIONS => {
1038 'IDENTIFIER' => 26
1040 GOTOS => {
1041 'identifier' => 134
1044 {#State 124
1045 DEFAULT => -116
1047 {#State 125
1048 ACTIONS => {
1049 "{" => 136
1051 DEFAULT => -70,
1052 GOTOS => {
1053 'union_body' => 137,
1054 'opt_union_body' => 135
1057 {#State 126
1058 DEFAULT => -37
1060 {#State 127
1061 ACTIONS => {
1062 "{" => 139
1064 DEFAULT => -60,
1065 GOTOS => {
1066 'struct_body' => 138,
1067 'opt_struct_body' => 140
1070 {#State 128
1071 ACTIONS => {
1072 "{" => 141
1074 DEFAULT => -43,
1075 GOTOS => {
1076 'opt_enum_body' => 143,
1077 'enum_body' => 142
1080 {#State 129
1081 ACTIONS => {
1082 "{" => 145
1084 DEFAULT => -51,
1085 GOTOS => {
1086 'bitmap_body' => 146,
1087 'opt_bitmap_body' => 144
1090 {#State 130
1091 ACTIONS => {
1092 "(" => 147
1095 {#State 131
1096 ACTIONS => {
1097 'IDENTIFIER' => 26,
1098 "*" => 149
1100 GOTOS => {
1101 'identifier' => 148
1104 {#State 132
1105 ACTIONS => {
1106 'CONSTANT' => 48,
1107 'TEXT' => 16,
1108 'IDENTIFIER' => 26
1110 DEFAULT => -95,
1111 GOTOS => {
1112 'identifier' => 50,
1113 'anytext' => 150,
1114 'text' => 51,
1115 'constant' => 47
1118 {#State 133
1119 ACTIONS => {
1120 'CONSTANT' => 48,
1121 'TEXT' => 16,
1122 'IDENTIFIER' => 26
1124 DEFAULT => -95,
1125 GOTOS => {
1126 'identifier' => 50,
1127 'anytext' => 151,
1128 'text' => 51,
1129 'constant' => 47
1132 {#State 134
1133 ACTIONS => {
1134 "[" => 152
1136 DEFAULT => -84,
1137 GOTOS => {
1138 'array_len' => 153
1141 {#State 135
1142 DEFAULT => -72
1144 {#State 136
1145 DEFAULT => -67,
1146 GOTOS => {
1147 'union_elements' => 154
1150 {#State 137
1151 DEFAULT => -71
1153 {#State 138
1154 DEFAULT => -61
1156 {#State 139
1157 DEFAULT => -76,
1158 GOTOS => {
1159 'element_list1' => 155
1162 {#State 140
1163 DEFAULT => -62
1165 {#State 141
1166 ACTIONS => {
1167 'IDENTIFIER' => 26
1169 GOTOS => {
1170 'identifier' => 156,
1171 'enum_element' => 157,
1172 'enum_elements' => 158
1175 {#State 142
1176 DEFAULT => -44
1178 {#State 143
1179 DEFAULT => -45
1181 {#State 144
1182 DEFAULT => -53
1184 {#State 145
1185 ACTIONS => {
1186 'IDENTIFIER' => 26
1188 DEFAULT => -56,
1189 GOTOS => {
1190 'identifier' => 161,
1191 'bitmap_element' => 160,
1192 'bitmap_elements' => 159,
1193 'opt_bitmap_elements' => 162
1196 {#State 146
1197 DEFAULT => -52
1199 {#State 147
1200 ACTIONS => {
1201 "," => -80,
1202 "void" => 166,
1203 "const" => 164,
1204 ")" => -80
1206 DEFAULT => -78,
1207 GOTOS => {
1208 'optional_const' => 163,
1209 'element_list2' => 165
1212 {#State 148
1213 ACTIONS => {
1214 "[" => 152,
1215 "=" => 168
1217 GOTOS => {
1218 'array_len' => 167
1221 {#State 149
1222 DEFAULT => -75
1224 {#State 150
1225 ACTIONS => {
1226 "-" => 68,
1227 ":" => 67,
1228 "<" => 70,
1229 "+" => 72,
1230 "~" => 71,
1231 "*" => 79,
1232 "?" => 69,
1233 "{" => 73,
1234 "&" => 74,
1235 "/" => 75,
1236 "=" => 76,
1237 "(" => 77,
1238 "|" => 78,
1239 "." => 80,
1240 ">" => 81
1242 DEFAULT => -113
1244 {#State 151
1245 ACTIONS => {
1246 ":" => 67,
1247 "<" => 70,
1248 "~" => 71,
1249 "?" => 69,
1250 "{" => 73,
1251 "=" => 76
1253 DEFAULT => -112
1255 {#State 152
1256 ACTIONS => {
1257 'CONSTANT' => 48,
1258 'TEXT' => 16,
1259 "]" => 169,
1260 'IDENTIFIER' => 26
1262 DEFAULT => -95,
1263 GOTOS => {
1264 'identifier' => 50,
1265 'anytext' => 170,
1266 'text' => 51,
1267 'constant' => 47
1270 {#State 153
1271 ACTIONS => {
1272 ";" => 171
1275 {#State 154
1276 ACTIONS => {
1277 "}" => 172
1279 DEFAULT => -87,
1280 GOTOS => {
1281 'optional_base_element' => 174,
1282 'property_list' => 173
1285 {#State 155
1286 ACTIONS => {
1287 "}" => 175
1289 DEFAULT => -87,
1290 GOTOS => {
1291 'base_element' => 176,
1292 'property_list' => 177
1295 {#State 156
1296 ACTIONS => {
1297 "=" => 178
1299 DEFAULT => -48
1301 {#State 157
1302 DEFAULT => -46
1304 {#State 158
1305 ACTIONS => {
1306 "}" => 179,
1307 "," => 180
1310 {#State 159
1311 ACTIONS => {
1312 "," => 181
1314 DEFAULT => -57
1316 {#State 160
1317 DEFAULT => -54
1319 {#State 161
1320 ACTIONS => {
1321 "=" => 182
1324 {#State 162
1325 ACTIONS => {
1326 "}" => 183
1329 {#State 163
1330 DEFAULT => -87,
1331 GOTOS => {
1332 'base_element' => 184,
1333 'property_list' => 177
1336 {#State 164
1337 DEFAULT => -79
1339 {#State 165
1340 ACTIONS => {
1341 "," => 185,
1342 ")" => 186
1345 {#State 166
1346 DEFAULT => -81
1348 {#State 167
1349 ACTIONS => {
1350 "=" => 187
1353 {#State 168
1354 ACTIONS => {
1355 'CONSTANT' => 48,
1356 'TEXT' => 16,
1357 'IDENTIFIER' => 26
1359 DEFAULT => -95,
1360 GOTOS => {
1361 'identifier' => 50,
1362 'anytext' => 188,
1363 'text' => 51,
1364 'constant' => 47
1367 {#State 169
1368 ACTIONS => {
1369 "[" => 152
1371 DEFAULT => -84,
1372 GOTOS => {
1373 'array_len' => 189
1376 {#State 170
1377 ACTIONS => {
1378 "-" => 68,
1379 ":" => 67,
1380 "?" => 69,
1381 "<" => 70,
1382 "+" => 72,
1383 "~" => 71,
1384 "&" => 74,
1385 "{" => 73,
1386 "/" => 75,
1387 "=" => 76,
1388 "|" => 78,
1389 "(" => 77,
1390 "*" => 79,
1391 "." => 80,
1392 "]" => 190,
1393 ">" => 81
1396 {#State 171
1397 DEFAULT => -29
1399 {#State 172
1400 DEFAULT => -69
1402 {#State 173
1403 ACTIONS => {
1404 "[" => 20
1406 DEFAULT => -87,
1407 GOTOS => {
1408 'base_or_empty' => 191,
1409 'base_element' => 192,
1410 'empty_element' => 193,
1411 'property_list' => 194
1414 {#State 174
1415 DEFAULT => -68
1417 {#State 175
1418 DEFAULT => -59
1420 {#State 176
1421 ACTIONS => {
1422 ";" => 195
1425 {#State 177
1426 ACTIONS => {
1427 'IDENTIFIER' => 26,
1428 "signed" => 98,
1429 'void' => 92,
1430 "unsigned" => 102,
1431 "[" => 20
1433 DEFAULT => -87,
1434 GOTOS => {
1435 'existingtype' => 99,
1436 'bitmap' => 56,
1437 'usertype' => 94,
1438 'property_list' => 93,
1439 'identifier' => 95,
1440 'struct' => 61,
1441 'enum' => 64,
1442 'type' => 196,
1443 'union' => 66,
1444 'sign' => 96
1447 {#State 178
1448 ACTIONS => {
1449 'CONSTANT' => 48,
1450 'TEXT' => 16,
1451 'IDENTIFIER' => 26
1453 DEFAULT => -95,
1454 GOTOS => {
1455 'identifier' => 50,
1456 'anytext' => 197,
1457 'text' => 51,
1458 'constant' => 47
1461 {#State 179
1462 DEFAULT => -42
1464 {#State 180
1465 ACTIONS => {
1466 'IDENTIFIER' => 26
1468 GOTOS => {
1469 'identifier' => 156,
1470 'enum_element' => 198
1473 {#State 181
1474 ACTIONS => {
1475 'IDENTIFIER' => 26
1477 GOTOS => {
1478 'identifier' => 161,
1479 'bitmap_element' => 199
1482 {#State 182
1483 ACTIONS => {
1484 'CONSTANT' => 48,
1485 'TEXT' => 16,
1486 'IDENTIFIER' => 26
1488 DEFAULT => -95,
1489 GOTOS => {
1490 'identifier' => 50,
1491 'anytext' => 200,
1492 'text' => 51,
1493 'constant' => 47
1496 {#State 183
1497 DEFAULT => -50
1499 {#State 184
1500 DEFAULT => -82
1502 {#State 185
1503 ACTIONS => {
1504 "const" => 164
1506 DEFAULT => -78,
1507 GOTOS => {
1508 'optional_const' => 201
1511 {#State 186
1512 ACTIONS => {
1513 ";" => 202
1516 {#State 187
1517 ACTIONS => {
1518 'CONSTANT' => 48,
1519 'TEXT' => 16,
1520 'IDENTIFIER' => 26
1522 DEFAULT => -95,
1523 GOTOS => {
1524 'identifier' => 50,
1525 'anytext' => 203,
1526 'text' => 51,
1527 'constant' => 47
1530 {#State 188
1531 ACTIONS => {
1532 "-" => 68,
1533 ":" => 67,
1534 "?" => 69,
1535 "<" => 70,
1536 ";" => 204,
1537 "+" => 72,
1538 "~" => 71,
1539 "&" => 74,
1540 "{" => 73,
1541 "/" => 75,
1542 "=" => 76,
1543 "|" => 78,
1544 "(" => 77,
1545 "*" => 79,
1546 "." => 80,
1547 ">" => 81
1550 {#State 189
1551 DEFAULT => -85
1553 {#State 190
1554 ACTIONS => {
1555 "[" => 152
1557 DEFAULT => -84,
1558 GOTOS => {
1559 'array_len' => 205
1562 {#State 191
1563 DEFAULT => -66
1565 {#State 192
1566 ACTIONS => {
1567 ";" => 206
1570 {#State 193
1571 DEFAULT => -65
1573 {#State 194
1574 ACTIONS => {
1575 'IDENTIFIER' => 26,
1576 "signed" => 98,
1577 ";" => 207,
1578 'void' => 92,
1579 "unsigned" => 102,
1580 "[" => 20
1582 DEFAULT => -87,
1583 GOTOS => {
1584 'existingtype' => 99,
1585 'bitmap' => 56,
1586 'usertype' => 94,
1587 'property_list' => 93,
1588 'identifier' => 95,
1589 'struct' => 61,
1590 'enum' => 64,
1591 'type' => 196,
1592 'union' => 66,
1593 'sign' => 96
1596 {#State 195
1597 DEFAULT => -77
1599 {#State 196
1600 DEFAULT => -74,
1601 GOTOS => {
1602 'pointers' => 208
1605 {#State 197
1606 ACTIONS => {
1607 "-" => 68,
1608 ":" => 67,
1609 "<" => 70,
1610 "+" => 72,
1611 "~" => 71,
1612 "*" => 79,
1613 "?" => 69,
1614 "{" => 73,
1615 "&" => 74,
1616 "/" => 75,
1617 "=" => 76,
1618 "(" => 77,
1619 "|" => 78,
1620 "." => 80,
1621 ">" => 81
1623 DEFAULT => -49
1625 {#State 198
1626 DEFAULT => -47
1628 {#State 199
1629 DEFAULT => -55
1631 {#State 200
1632 ACTIONS => {
1633 "-" => 68,
1634 ":" => 67,
1635 "<" => 70,
1636 "+" => 72,
1637 "~" => 71,
1638 "*" => 79,
1639 "?" => 69,
1640 "{" => 73,
1641 "&" => 74,
1642 "/" => 75,
1643 "=" => 76,
1644 "(" => 77,
1645 "|" => 78,
1646 "." => 80,
1647 ">" => 81
1649 DEFAULT => -58
1651 {#State 201
1652 DEFAULT => -87,
1653 GOTOS => {
1654 'base_element' => 209,
1655 'property_list' => 177
1658 {#State 202
1659 DEFAULT => -28
1661 {#State 203
1662 ACTIONS => {
1663 "-" => 68,
1664 ":" => 67,
1665 "?" => 69,
1666 "<" => 70,
1667 ";" => 210,
1668 "+" => 72,
1669 "~" => 71,
1670 "&" => 74,
1671 "{" => 73,
1672 "/" => 75,
1673 "=" => 76,
1674 "|" => 78,
1675 "(" => 77,
1676 "*" => 79,
1677 "." => 80,
1678 ">" => 81
1681 {#State 204
1682 DEFAULT => -26
1684 {#State 205
1685 DEFAULT => -86
1687 {#State 206
1688 DEFAULT => -64
1690 {#State 207
1691 DEFAULT => -63
1693 {#State 208
1694 ACTIONS => {
1695 'IDENTIFIER' => 26,
1696 "*" => 149
1698 GOTOS => {
1699 'identifier' => 211
1702 {#State 209
1703 DEFAULT => -83
1705 {#State 210
1706 DEFAULT => -27
1708 {#State 211
1709 ACTIONS => {
1710 "[" => 152
1712 DEFAULT => -84,
1713 GOTOS => {
1714 'array_len' => 212
1717 {#State 212
1718 DEFAULT => -73
1721 yyrules =>
1723 [#Rule 0
1724 '$start', 2, undef
1726 [#Rule 1
1727 'idl', 0, undef
1729 [#Rule 2
1730 'idl', 2,
1732 #line 20 "./../pidl/idl.yp"
1733 { push(@{$_[1]}, $_[2]); $_[1] }
1735 [#Rule 3
1736 'idl', 2,
1738 #line 22 "./../pidl/idl.yp"
1739 { push(@{$_[1]}, $_[2]); $_[1] }
1741 [#Rule 4
1742 'idl', 2,
1744 #line 24 "./../pidl/idl.yp"
1745 { push(@{$_[1]}, $_[2]); $_[1] }
1747 [#Rule 5
1748 'idl', 2,
1750 #line 26 "./../pidl/idl.yp"
1751 { push(@{$_[1]}, $_[2]); $_[1] }
1753 [#Rule 6
1754 'idl', 2,
1756 #line 28 "./../pidl/idl.yp"
1757 { push(@{$_[1]}, $_[2]); $_[1] }
1759 [#Rule 7
1760 'idl', 2,
1762 #line 30 "./../pidl/idl.yp"
1763 { push(@{$_[1]}, $_[2]); $_[1] }
1765 [#Rule 8
1766 'import', 3,
1768 #line 35 "./../pidl/idl.yp"
1770 "TYPE" => "IMPORT",
1771 "PATHS" => $_[2],
1772 "FILE" => $_[0]->YYData->{FILE},
1773 "LINE" => $_[0]->YYData->{LINE},
1776 [#Rule 9
1777 'include', 3,
1779 #line 45 "./../pidl/idl.yp"
1781 "TYPE" => "INCLUDE",
1782 "PATHS" => $_[2],
1783 "FILE" => $_[0]->YYData->{FILE},
1784 "LINE" => $_[0]->YYData->{LINE},
1787 [#Rule 10
1788 'importlib', 3,
1790 #line 55 "./../pidl/idl.yp"
1792 "TYPE" => "IMPORTLIB",
1793 "PATHS" => $_[2],
1794 "FILE" => $_[0]->YYData->{FILE},
1795 "LINE" => $_[0]->YYData->{LINE},
1798 [#Rule 11
1799 'commalist', 1,
1801 #line 64 "./../pidl/idl.yp"
1802 { [ $_[1] ] }
1804 [#Rule 12
1805 'commalist', 3,
1807 #line 66 "./../pidl/idl.yp"
1808 { push(@{$_[1]}, $_[3]); $_[1] }
1810 [#Rule 13
1811 'coclass', 7,
1813 #line 71 "./../pidl/idl.yp"
1815 "TYPE" => "COCLASS",
1816 "PROPERTIES" => $_[1],
1817 "NAME" => $_[3],
1818 "DATA" => $_[5],
1819 "FILE" => $_[0]->YYData->{FILE},
1820 "LINE" => $_[0]->YYData->{LINE},
1823 [#Rule 14
1824 'interface_names', 0, undef
1826 [#Rule 15
1827 'interface_names', 4,
1829 #line 84 "./../pidl/idl.yp"
1830 { push(@{$_[1]}, $_[2]); $_[1] }
1832 [#Rule 16
1833 'interface', 8,
1835 #line 89 "./../pidl/idl.yp"
1837 "TYPE" => "INTERFACE",
1838 "PROPERTIES" => $_[1],
1839 "NAME" => $_[3],
1840 "BASE" => $_[4],
1841 "DATA" => $_[6],
1842 "FILE" => $_[0]->YYData->{FILE},
1843 "LINE" => $_[0]->YYData->{LINE},
1846 [#Rule 17
1847 'base_interface', 0, undef
1849 [#Rule 18
1850 'base_interface', 2,
1852 #line 103 "./../pidl/idl.yp"
1853 { $_[2] }
1855 [#Rule 19
1856 'cpp_quote', 4,
1858 #line 109 "./../pidl/idl.yp"
1860 "TYPE" => "CPP_QUOTE",
1861 "DATA" => $_[3],
1862 "FILE" => $_[0]->YYData->{FILE},
1863 "LINE" => $_[0]->YYData->{LINE},
1866 [#Rule 20
1867 'definitions', 1,
1869 #line 118 "./../pidl/idl.yp"
1870 { [ $_[1] ] }
1872 [#Rule 21
1873 'definitions', 2,
1875 #line 120 "./../pidl/idl.yp"
1876 { push(@{$_[1]}, $_[2]); $_[1] }
1878 [#Rule 22
1879 'definition', 1, undef
1881 [#Rule 23
1882 'definition', 1, undef
1884 [#Rule 24
1885 'definition', 1, undef
1887 [#Rule 25
1888 'definition', 1, undef
1890 [#Rule 26
1891 'const', 7,
1893 #line 135 "./../pidl/idl.yp"
1895 "TYPE" => "CONST",
1896 "DTYPE" => $_[2],
1897 "POINTERS" => $_[3],
1898 "NAME" => $_[4],
1899 "VALUE" => $_[6],
1900 "FILE" => $_[0]->YYData->{FILE},
1901 "LINE" => $_[0]->YYData->{LINE},
1904 [#Rule 27
1905 'const', 8,
1907 #line 146 "./../pidl/idl.yp"
1909 "TYPE" => "CONST",
1910 "DTYPE" => $_[2],
1911 "POINTERS" => $_[3],
1912 "NAME" => $_[4],
1913 "ARRAY_LEN" => $_[5],
1914 "VALUE" => $_[7],
1915 "FILE" => $_[0]->YYData->{FILE},
1916 "LINE" => $_[0]->YYData->{LINE},
1919 [#Rule 28
1920 'function', 7,
1922 #line 160 "./../pidl/idl.yp"
1924 "TYPE" => "FUNCTION",
1925 "NAME" => $_[3],
1926 "RETURN_TYPE" => $_[2],
1927 "PROPERTIES" => $_[1],
1928 "ELEMENTS" => $_[5],
1929 "FILE" => $_[0]->YYData->{FILE},
1930 "LINE" => $_[0]->YYData->{LINE},
1933 [#Rule 29
1934 'typedef', 6,
1936 #line 173 "./../pidl/idl.yp"
1938 "TYPE" => "TYPEDEF",
1939 "PROPERTIES" => $_[1],
1940 "NAME" => $_[4],
1941 "DATA" => $_[3],
1942 "ARRAY_LEN" => $_[5],
1943 "FILE" => $_[0]->YYData->{FILE},
1944 "LINE" => $_[0]->YYData->{LINE},
1947 [#Rule 30
1948 'usertype', 1, undef
1950 [#Rule 31
1951 'usertype', 1, undef
1953 [#Rule 32
1954 'usertype', 1, undef
1956 [#Rule 33
1957 'usertype', 1, undef
1959 [#Rule 34
1960 'typedecl', 2,
1962 #line 195 "./../pidl/idl.yp"
1963 { $_[1] }
1965 [#Rule 35
1966 'sign', 1, undef
1968 [#Rule 36
1969 'sign', 1, undef
1971 [#Rule 37
1972 'existingtype', 2,
1974 #line 205 "./../pidl/idl.yp"
1975 { ($_[1]?$_[1]:"signed") ." $_[2]" }
1977 [#Rule 38
1978 'existingtype', 1, undef
1980 [#Rule 39
1981 'type', 1, undef
1983 [#Rule 40
1984 'type', 1, undef
1986 [#Rule 41
1987 'type', 1,
1989 #line 215 "./../pidl/idl.yp"
1990 { "void" }
1992 [#Rule 42
1993 'enum_body', 3,
1995 #line 219 "./../pidl/idl.yp"
1996 { $_[2] }
1998 [#Rule 43
1999 'opt_enum_body', 0, undef
2001 [#Rule 44
2002 'opt_enum_body', 1, undef
2004 [#Rule 45
2005 'enum', 4,
2007 #line 230 "./../pidl/idl.yp"
2009 "TYPE" => "ENUM",
2010 "PROPERTIES" => $_[1],
2011 "NAME" => $_[3],
2012 "ELEMENTS" => $_[4],
2013 "FILE" => $_[0]->YYData->{FILE},
2014 "LINE" => $_[0]->YYData->{LINE},
2017 [#Rule 46
2018 'enum_elements', 1,
2020 #line 241 "./../pidl/idl.yp"
2021 { [ $_[1] ] }
2023 [#Rule 47
2024 'enum_elements', 3,
2026 #line 243 "./../pidl/idl.yp"
2027 { push(@{$_[1]}, $_[3]); $_[1] }
2029 [#Rule 48
2030 'enum_element', 1, undef
2032 [#Rule 49
2033 'enum_element', 3,
2035 #line 249 "./../pidl/idl.yp"
2036 { "$_[1]$_[2]$_[3]" }
2038 [#Rule 50
2039 'bitmap_body', 3,
2041 #line 253 "./../pidl/idl.yp"
2042 { $_[2] }
2044 [#Rule 51
2045 'opt_bitmap_body', 0, undef
2047 [#Rule 52
2048 'opt_bitmap_body', 1, undef
2050 [#Rule 53
2051 'bitmap', 4,
2053 #line 264 "./../pidl/idl.yp"
2055 "TYPE" => "BITMAP",
2056 "PROPERTIES" => $_[1],
2057 "NAME" => $_[3],
2058 "ELEMENTS" => $_[4],
2059 "FILE" => $_[0]->YYData->{FILE},
2060 "LINE" => $_[0]->YYData->{LINE},
2063 [#Rule 54
2064 'bitmap_elements', 1,
2066 #line 275 "./../pidl/idl.yp"
2067 { [ $_[1] ] }
2069 [#Rule 55
2070 'bitmap_elements', 3,
2072 #line 277 "./../pidl/idl.yp"
2073 { push(@{$_[1]}, $_[3]); $_[1] }
2075 [#Rule 56
2076 'opt_bitmap_elements', 0, undef
2078 [#Rule 57
2079 'opt_bitmap_elements', 1, undef
2081 [#Rule 58
2082 'bitmap_element', 3,
2084 #line 287 "./../pidl/idl.yp"
2085 { "$_[1] ( $_[3] )" }
2087 [#Rule 59
2088 'struct_body', 3,
2090 #line 291 "./../pidl/idl.yp"
2091 { $_[2] }
2093 [#Rule 60
2094 'opt_struct_body', 0, undef
2096 [#Rule 61
2097 'opt_struct_body', 1, undef
2099 [#Rule 62
2100 'struct', 4,
2102 #line 302 "./../pidl/idl.yp"
2104 "TYPE" => "STRUCT",
2105 "PROPERTIES" => $_[1],
2106 "NAME" => $_[3],
2107 "ELEMENTS" => $_[4],
2108 "FILE" => $_[0]->YYData->{FILE},
2109 "LINE" => $_[0]->YYData->{LINE},
2112 [#Rule 63
2113 'empty_element', 2,
2115 #line 314 "./../pidl/idl.yp"
2117 "NAME" => "",
2118 "TYPE" => "EMPTY",
2119 "PROPERTIES" => $_[1],
2120 "POINTERS" => 0,
2121 "ARRAY_LEN" => [],
2122 "FILE" => $_[0]->YYData->{FILE},
2123 "LINE" => $_[0]->YYData->{LINE},
2126 [#Rule 64
2127 'base_or_empty', 2, undef
2129 [#Rule 65
2130 'base_or_empty', 1, undef
2132 [#Rule 66
2133 'optional_base_element', 2,
2135 #line 331 "./../pidl/idl.yp"
2136 { $_[2]->{PROPERTIES} = FlattenHash([$_[1],$_[2]->{PROPERTIES}]); $_[2] }
2138 [#Rule 67
2139 'union_elements', 0, undef
2141 [#Rule 68
2142 'union_elements', 2,
2144 #line 337 "./../pidl/idl.yp"
2145 { push(@{$_[1]}, $_[2]); $_[1] }
2147 [#Rule 69
2148 'union_body', 3,
2150 #line 341 "./../pidl/idl.yp"
2151 { $_[2] }
2153 [#Rule 70
2154 'opt_union_body', 0, undef
2156 [#Rule 71
2157 'opt_union_body', 1, undef
2159 [#Rule 72
2160 'union', 4,
2162 #line 352 "./../pidl/idl.yp"
2164 "TYPE" => "UNION",
2165 "PROPERTIES" => $_[1],
2166 "NAME" => $_[3],
2167 "ELEMENTS" => $_[4],
2168 "FILE" => $_[0]->YYData->{FILE},
2169 "LINE" => $_[0]->YYData->{LINE},
2172 [#Rule 73
2173 'base_element', 5,
2175 #line 364 "./../pidl/idl.yp"
2177 "NAME" => $_[4],
2178 "TYPE" => $_[2],
2179 "PROPERTIES" => $_[1],
2180 "POINTERS" => $_[3],
2181 "ARRAY_LEN" => $_[5],
2182 "FILE" => $_[0]->YYData->{FILE},
2183 "LINE" => $_[0]->YYData->{LINE},
2186 [#Rule 74
2187 'pointers', 0,
2189 #line 377 "./../pidl/idl.yp"
2190 { 0 }
2192 [#Rule 75
2193 'pointers', 2,
2195 #line 379 "./../pidl/idl.yp"
2196 { $_[1]+1 }
2198 [#Rule 76
2199 'element_list1', 0,
2201 #line 384 "./../pidl/idl.yp"
2202 { [] }
2204 [#Rule 77
2205 'element_list1', 3,
2207 #line 386 "./../pidl/idl.yp"
2208 { push(@{$_[1]}, $_[2]); $_[1] }
2210 [#Rule 78
2211 'optional_const', 0, undef
2213 [#Rule 79
2214 'optional_const', 1, undef
2216 [#Rule 80
2217 'element_list2', 0, undef
2219 [#Rule 81
2220 'element_list2', 1, undef
2222 [#Rule 82
2223 'element_list2', 2,
2225 #line 400 "./../pidl/idl.yp"
2226 { [ $_[2] ] }
2228 [#Rule 83
2229 'element_list2', 4,
2231 #line 402 "./../pidl/idl.yp"
2232 { push(@{$_[1]}, $_[4]); $_[1] }
2234 [#Rule 84
2235 'array_len', 0, undef
2237 [#Rule 85
2238 'array_len', 3,
2240 #line 408 "./../pidl/idl.yp"
2241 { push(@{$_[3]}, "*"); $_[3] }
2243 [#Rule 86
2244 'array_len', 4,
2246 #line 410 "./../pidl/idl.yp"
2247 { push(@{$_[4]}, "$_[2]"); $_[4] }
2249 [#Rule 87
2250 'property_list', 0, undef
2252 [#Rule 88
2253 'property_list', 4,
2255 #line 416 "./../pidl/idl.yp"
2256 { FlattenHash([$_[1],$_[3]]); }
2258 [#Rule 89
2259 'properties', 1,
2261 #line 420 "./../pidl/idl.yp"
2262 { $_[1] }
2264 [#Rule 90
2265 'properties', 3,
2267 #line 422 "./../pidl/idl.yp"
2268 { FlattenHash([$_[1], $_[3]]); }
2270 [#Rule 91
2271 'property', 1,
2273 #line 426 "./../pidl/idl.yp"
2274 {{ "$_[1]" => "1" }}
2276 [#Rule 92
2277 'property', 4,
2279 #line 428 "./../pidl/idl.yp"
2280 {{ "$_[1]" => "$_[3]" }}
2282 [#Rule 93
2283 'commalisttext', 1, undef
2285 [#Rule 94
2286 'commalisttext', 3,
2288 #line 434 "./../pidl/idl.yp"
2289 { "$_[1],$_[3]" }
2291 [#Rule 95
2292 'anytext', 0,
2294 #line 439 "./../pidl/idl.yp"
2295 { "" }
2297 [#Rule 96
2298 'anytext', 1, undef
2300 [#Rule 97
2301 'anytext', 1, undef
2303 [#Rule 98
2304 'anytext', 1, undef
2306 [#Rule 99
2307 'anytext', 3,
2309 #line 447 "./../pidl/idl.yp"
2310 { "$_[1]$_[2]$_[3]" }
2312 [#Rule 100
2313 'anytext', 3,
2315 #line 449 "./../pidl/idl.yp"
2316 { "$_[1]$_[2]$_[3]" }
2318 [#Rule 101
2319 'anytext', 3,
2321 #line 451 "./../pidl/idl.yp"
2322 { "$_[1]$_[2]$_[3]" }
2324 [#Rule 102
2325 'anytext', 3,
2327 #line 453 "./../pidl/idl.yp"
2328 { "$_[1]$_[2]$_[3]" }
2330 [#Rule 103
2331 'anytext', 3,
2333 #line 455 "./../pidl/idl.yp"
2334 { "$_[1]$_[2]$_[3]" }
2336 [#Rule 104
2337 'anytext', 3,
2339 #line 457 "./../pidl/idl.yp"
2340 { "$_[1]$_[2]$_[3]" }
2342 [#Rule 105
2343 'anytext', 3,
2345 #line 459 "./../pidl/idl.yp"
2346 { "$_[1]$_[2]$_[3]" }
2348 [#Rule 106
2349 'anytext', 3,
2351 #line 461 "./../pidl/idl.yp"
2352 { "$_[1]$_[2]$_[3]" }
2354 [#Rule 107
2355 'anytext', 3,
2357 #line 463 "./../pidl/idl.yp"
2358 { "$_[1]$_[2]$_[3]" }
2360 [#Rule 108
2361 'anytext', 3,
2363 #line 465 "./../pidl/idl.yp"
2364 { "$_[1]$_[2]$_[3]" }
2366 [#Rule 109
2367 'anytext', 3,
2369 #line 467 "./../pidl/idl.yp"
2370 { "$_[1]$_[2]$_[3]" }
2372 [#Rule 110
2373 'anytext', 3,
2375 #line 469 "./../pidl/idl.yp"
2376 { "$_[1]$_[2]$_[3]" }
2378 [#Rule 111
2379 'anytext', 3,
2381 #line 471 "./../pidl/idl.yp"
2382 { "$_[1]$_[2]$_[3]" }
2384 [#Rule 112
2385 'anytext', 5,
2387 #line 473 "./../pidl/idl.yp"
2388 { "$_[1]$_[2]$_[3]$_[4]$_[5]" }
2390 [#Rule 113
2391 'anytext', 5,
2393 #line 475 "./../pidl/idl.yp"
2394 { "$_[1]$_[2]$_[3]$_[4]$_[5]" }
2396 [#Rule 114
2397 'identifier', 1, undef
2399 [#Rule 115
2400 'optional_identifier', 0, undef
2402 [#Rule 116
2403 'optional_identifier', 1, undef
2405 [#Rule 117
2406 'constant', 1, undef
2408 [#Rule 118
2409 'text', 1,
2411 #line 493 "./../pidl/idl.yp"
2412 { "\"$_[1]\"" }
2414 [#Rule 119
2415 'optional_semicolon', 0, undef
2417 [#Rule 120
2418 'optional_semicolon', 1, undef
2421 @_);
2422 bless($self,$class);
2425 #line 505 "./../pidl/idl.yp"
2428 use Parse::Pidl qw(error);
2430 #####################################################################
2431 # flatten an array of hashes into a single hash
2432 sub FlattenHash($)
2434 my $a = shift;
2435 my %b;
2436 for my $d (@{$a}) {
2437 for my $k (keys %{$d}) {
2438 $b{$k} = $d->{$k};
2441 return \%b;
2444 #####################################################################
2445 # traverse a perl data structure removing any empty arrays or
2446 # hashes and any hash elements that map to undef
2447 sub CleanData($)
2449 sub CleanData($);
2450 my($v) = shift;
2452 return undef if (not defined($v));
2454 if (ref($v) eq "ARRAY") {
2455 foreach my $i (0 .. $#{$v}) {
2456 CleanData($v->[$i]);
2458 # this removes any undefined elements from the array
2459 @{$v} = grep { defined $_ } @{$v};
2460 } elsif (ref($v) eq "HASH") {
2461 foreach my $x (keys %{$v}) {
2462 CleanData($v->{$x});
2463 if (!defined $v->{$x}) {
2464 delete($v->{$x});
2465 next;
2470 return $v;
2473 sub _Error {
2474 if (exists $_[0]->YYData->{ERRMSG}) {
2475 error($_[0]->YYData, $_[0]->YYData->{ERRMSG});
2476 delete $_[0]->YYData->{ERRMSG};
2477 return;
2480 my $last_token = $_[0]->YYData->{LAST_TOKEN};
2482 error($_[0]->YYData, "Syntax error near '$last_token'");
2485 sub _Lexer($)
2487 my($parser)=shift;
2489 $parser->YYData->{INPUT} or return('',undef);
2491 again:
2492 $parser->YYData->{INPUT} =~ s/^[ \t]*//;
2494 for ($parser->YYData->{INPUT}) {
2495 if (/^\#/) {
2496 if (s/^\# (\d+) \"(.*?)\"( \d+|)//) {
2497 $parser->YYData->{LINE} = $1-1;
2498 $parser->YYData->{FILE} = $2;
2499 goto again;
2501 if (s/^\#line (\d+) \"(.*?)\"( \d+|)//) {
2502 $parser->YYData->{LINE} = $1-1;
2503 $parser->YYData->{FILE} = $2;
2504 goto again;
2506 if (s/^(\#.*)$//m) {
2507 goto again;
2510 if (s/^(\n)//) {
2511 $parser->YYData->{LINE}++;
2512 goto again;
2514 if (s/^\"(.*?)\"//) {
2515 $parser->YYData->{LAST_TOKEN} = $1;
2516 return('TEXT',$1);
2518 if (s/^(\d+)(\W|$)/$2/) {
2519 $parser->YYData->{LAST_TOKEN} = $1;
2520 return('CONSTANT',$1);
2522 if (s/^([\w_]+)//) {
2523 $parser->YYData->{LAST_TOKEN} = $1;
2524 if ($1 =~
2525 /^(coclass|interface|import|importlib
2526 |include|cpp_quote|typedef
2527 |union|struct|enum|bitmap
2528 |void|const|unsigned|signed)$/x) {
2529 return $1;
2531 return('IDENTIFIER',$1);
2533 if (s/^(.)//s) {
2534 $parser->YYData->{LAST_TOKEN} = $1;
2535 return($1,$1);
2540 sub parse_string
2542 my ($data,$filename) = @_;
2544 my $self = new Parse::Pidl::IDL;
2546 $self->YYData->{FILE} = $filename;
2547 $self->YYData->{INPUT} = $data;
2548 $self->YYData->{LINE} = 0;
2549 $self->YYData->{LAST_TOKEN} = "NONE";
2551 my $idl = $self->YYParse( yylex => \&_Lexer, yyerror => \&_Error );
2553 return CleanData($idl);
2556 sub parse_file($$)
2558 my ($filename,$incdirs) = @_;
2560 my $saved_delim = $/;
2561 undef $/;
2562 my $cpp = $ENV{CPP};
2563 if (! defined $cpp) {
2564 $cpp = "cpp";
2566 my $includes = join('',map { " -I$_" } @$incdirs);
2567 my $data = `$cpp -D__PIDL__$includes -xc $filename`;
2568 $/ = $saved_delim;
2570 return parse_string($data, $filename);