source: trunk/server/pidl/lib/Parse/Pidl/IDL.pm

Last change on this file was 862, checked in by Silvan Scherrer, 11 years ago

Samba Server: update trunk to 3.6.23

File size: 37.3 KB
Line 
1####################################################################
2#
3# This file was generated using Parse::Yapp version 1.05.
4#
5# Don't edit this file, use source file instead.
6#
7# ANY CHANGE MADE HERE WILL BE LOST !
8#
9####################################################################
10package Parse::Pidl::IDL;
11use vars qw ( @ISA );
12use strict;
13
14@ISA= qw ( Parse::Yapp::Driver );
15use Parse::Yapp::Driver;
16
17
18
19sub new {
20 my($class)=shift;
21 ref($class)
22 and $class=ref($class);
23
24 my($self)=$class->SUPER::new( yyversion => '1.05',
25 yystates =>
26[
27 {#State 0
28 DEFAULT => -1,
29 GOTOS => {
30 'idl' => 1
31 }
32 },
33 {#State 1
34 ACTIONS => {
35 '' => 2,
36 "cpp_quote" => 3,
37 "importlib" => 4,
38 "import" => 7,
39 "include" => 13
40 },
41 DEFAULT => -89,
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
50 }
51 },
52 {#State 2
53 DEFAULT => 0
54 },
55 {#State 3
56 ACTIONS => {
57 "(" => 14
58 }
59 },
60 {#State 4
61 ACTIONS => {
62 'TEXT' => 16
63 },
64 GOTOS => {
65 'commalist' => 15,
66 'text' => 17
67 }
68 },
69 {#State 5
70 DEFAULT => -5
71 },
72 {#State 6
73 ACTIONS => {
74 "coclass" => 18,
75 "[" => 20,
76 "interface" => 19
77 }
78 },
79 {#State 7
80 ACTIONS => {
81 'TEXT' => 16
82 },
83 GOTOS => {
84 'commalist' => 21,
85 'text' => 17
86 }
87 },
88 {#State 8
89 DEFAULT => -4
90 },
91 {#State 9
92 DEFAULT => -2
93 },
94 {#State 10
95 DEFAULT => -6
96 },
97 {#State 11
98 DEFAULT => -7
99 },
100 {#State 12
101 DEFAULT => -3
102 },
103 {#State 13
104 ACTIONS => {
105 'TEXT' => 16
106 },
107 GOTOS => {
108 'commalist' => 22,
109 'text' => 17
110 }
111 },
112 {#State 14
113 ACTIONS => {
114 'TEXT' => 16
115 },
116 GOTOS => {
117 'text' => 23
118 }
119 },
120 {#State 15
121 ACTIONS => {
122 ";" => 24,
123 "," => 25
124 }
125 },
126 {#State 16
127 DEFAULT => -120
128 },
129 {#State 17
130 DEFAULT => -11
131 },
132 {#State 18
133 ACTIONS => {
134 'IDENTIFIER' => 26
135 },
136 GOTOS => {
137 'identifier' => 27
138 }
139 },
140 {#State 19
141 ACTIONS => {
142 'IDENTIFIER' => 26
143 },
144 GOTOS => {
145 'identifier' => 28
146 }
147 },
148 {#State 20
149 ACTIONS => {
150 'IDENTIFIER' => 26
151 },
152 GOTOS => {
153 'identifier' => 30,
154 'property' => 31,
155 'properties' => 29
156 }
157 },
158 {#State 21
159 ACTIONS => {
160 ";" => 32,
161 "," => 25
162 }
163 },
164 {#State 22
165 ACTIONS => {
166 ";" => 33,
167 "," => 25
168 }
169 },
170 {#State 23
171 ACTIONS => {
172 ")" => 34
173 }
174 },
175 {#State 24
176 DEFAULT => -10
177 },
178 {#State 25
179 ACTIONS => {
180 'TEXT' => 16
181 },
182 GOTOS => {
183 'text' => 35
184 }
185 },
186 {#State 26
187 DEFAULT => -116
188 },
189 {#State 27
190 ACTIONS => {
191 "{" => 36
192 }
193 },
194 {#State 28
195 ACTIONS => {
196 ":" => 37
197 },
198 DEFAULT => -17,
199 GOTOS => {
200 'base_interface' => 38
201 }
202 },
203 {#State 29
204 ACTIONS => {
205 "," => 39,
206 "]" => 40
207 }
208 },
209 {#State 30
210 ACTIONS => {
211 "(" => 41
212 },
213 DEFAULT => -93
214 },
215 {#State 31
216 DEFAULT => -91
217 },
218 {#State 32
219 DEFAULT => -8
220 },
221 {#State 33
222 DEFAULT => -9
223 },
224 {#State 34
225 DEFAULT => -19
226 },
227 {#State 35
228 DEFAULT => -12
229 },
230 {#State 36
231 DEFAULT => -14,
232 GOTOS => {
233 'interface_names' => 42
234 }
235 },
236 {#State 37
237 ACTIONS => {
238 'IDENTIFIER' => 26
239 },
240 GOTOS => {
241 'identifier' => 43
242 }
243 },
244 {#State 38
245 ACTIONS => {
246 "{" => 44
247 }
248 },
249 {#State 39
250 ACTIONS => {
251 'IDENTIFIER' => 26
252 },
253 GOTOS => {
254 'identifier' => 30,
255 'property' => 45
256 }
257 },
258 {#State 40
259 DEFAULT => -90
260 },
261 {#State 41
262 ACTIONS => {
263 'CONSTANT' => 48,
264 'TEXT' => 16,
265 'IDENTIFIER' => 26
266 },
267 DEFAULT => -97,
268 GOTOS => {
269 'identifier' => 50,
270 'text' => 51,
271 'anytext' => 46,
272 'constant' => 47,
273 'commalisttext' => 49
274 }
275 },
276 {#State 42
277 ACTIONS => {
278 "}" => 52,
279 "interface" => 53
280 }
281 },
282 {#State 43
283 DEFAULT => -18
284 },
285 {#State 44
286 ACTIONS => {
287 "const" => 64
288 },
289 DEFAULT => -89,
290 GOTOS => {
291 'typedecl' => 54,
292 'function' => 55,
293 'pipe' => 56,
294 'definitions' => 58,
295 'bitmap' => 57,
296 'definition' => 61,
297 'property_list' => 60,
298 'usertype' => 59,
299 'const' => 63,
300 'struct' => 62,
301 'typedef' => 66,
302 'enum' => 65,
303 'union' => 67
304 }
305 },
306 {#State 45
307 DEFAULT => -92
308 },
309 {#State 46
310 ACTIONS => {
311 "-" => 69,
312 ":" => 68,
313 "<" => 71,
314 "+" => 73,
315 "~" => 72,
316 "*" => 80,
317 "?" => 70,
318 "{" => 74,
319 "&" => 75,
320 "/" => 76,
321 "=" => 77,
322 "(" => 78,
323 "|" => 79,
324 "." => 81,
325 ">" => 82
326 },
327 DEFAULT => -95
328 },
329 {#State 47
330 DEFAULT => -99
331 },
332 {#State 48
333 DEFAULT => -119
334 },
335 {#State 49
336 ACTIONS => {
337 "," => 83,
338 ")" => 84
339 }
340 },
341 {#State 50
342 DEFAULT => -98
343 },
344 {#State 51
345 DEFAULT => -100
346 },
347 {#State 52
348 ACTIONS => {
349 ";" => 86
350 },
351 DEFAULT => -121,
352 GOTOS => {
353 'optional_semicolon' => 85
354 }
355 },
356 {#State 53
357 ACTIONS => {
358 'IDENTIFIER' => 26
359 },
360 GOTOS => {
361 'identifier' => 87
362 }
363 },
364 {#State 54
365 DEFAULT => -25
366 },
367 {#State 55
368 DEFAULT => -22
369 },
370 {#State 56
371 DEFAULT => -34
372 },
373 {#State 57
374 DEFAULT => -33
375 },
376 {#State 58
377 ACTIONS => {
378 "}" => 88,
379 "const" => 64
380 },
381 DEFAULT => -89,
382 GOTOS => {
383 'typedecl' => 54,
384 'function' => 55,
385 'pipe' => 56,
386 'bitmap' => 57,
387 'definition' => 89,
388 'property_list' => 60,
389 'usertype' => 59,
390 'const' => 63,
391 'struct' => 62,
392 'typedef' => 66,
393 'enum' => 65,
394 'union' => 67
395 }
396 },
397 {#State 59
398 ACTIONS => {
399 ";" => 90
400 }
401 },
402 {#State 60
403 ACTIONS => {
404 "typedef" => 91,
405 'IDENTIFIER' => 26,
406 "signed" => 100,
407 "union" => 92,
408 "enum" => 101,
409 "bitmap" => 102,
410 'void' => 93,
411 "pipe" => 103,
412 "unsigned" => 104,
413 "[" => 20,
414 "struct" => 98
415 },
416 GOTOS => {
417 'existingtype' => 99,
418 'pipe' => 56,
419 'bitmap' => 57,
420 'usertype' => 95,
421 'property_list' => 94,
422 'identifier' => 96,
423 'struct' => 62,
424 'enum' => 65,
425 'type' => 105,
426 'union' => 67,
427 'sign' => 97
428 }
429 },
430 {#State 61
431 DEFAULT => -20
432 },
433 {#State 62
434 DEFAULT => -30
435 },
436 {#State 63
437 DEFAULT => -23
438 },
439 {#State 64
440 ACTIONS => {
441 'IDENTIFIER' => 26
442 },
443 GOTOS => {
444 'identifier' => 106
445 }
446 },
447 {#State 65
448 DEFAULT => -32
449 },
450 {#State 66
451 DEFAULT => -24
452 },
453 {#State 67
454 DEFAULT => -31
455 },
456 {#State 68
457 ACTIONS => {
458 'CONSTANT' => 48,
459 'TEXT' => 16,
460 'IDENTIFIER' => 26
461 },
462 DEFAULT => -97,
463 GOTOS => {
464 'identifier' => 50,
465 'anytext' => 107,
466 'text' => 51,
467 'constant' => 47
468 }
469 },
470 {#State 69
471 ACTIONS => {
472 'CONSTANT' => 48,
473 'TEXT' => 16,
474 'IDENTIFIER' => 26
475 },
476 DEFAULT => -97,
477 GOTOS => {
478 'identifier' => 50,
479 'anytext' => 108,
480 'text' => 51,
481 'constant' => 47
482 }
483 },
484 {#State 70
485 ACTIONS => {
486 'CONSTANT' => 48,
487 'TEXT' => 16,
488 'IDENTIFIER' => 26
489 },
490 DEFAULT => -97,
491 GOTOS => {
492 'identifier' => 50,
493 'anytext' => 109,
494 'text' => 51,
495 'constant' => 47
496 }
497 },
498 {#State 71
499 ACTIONS => {
500 'CONSTANT' => 48,
501 'TEXT' => 16,
502 'IDENTIFIER' => 26
503 },
504 DEFAULT => -97,
505 GOTOS => {
506 'identifier' => 50,
507 'anytext' => 110,
508 'text' => 51,
509 'constant' => 47
510 }
511 },
512 {#State 72
513 ACTIONS => {
514 'CONSTANT' => 48,
515 'TEXT' => 16,
516 'IDENTIFIER' => 26
517 },
518 DEFAULT => -97,
519 GOTOS => {
520 'identifier' => 50,
521 'anytext' => 111,
522 'text' => 51,
523 'constant' => 47
524 }
525 },
526 {#State 73
527 ACTIONS => {
528 'CONSTANT' => 48,
529 'TEXT' => 16,
530 'IDENTIFIER' => 26
531 },
532 DEFAULT => -97,
533 GOTOS => {
534 'identifier' => 50,
535 'anytext' => 112,
536 'text' => 51,
537 'constant' => 47
538 }
539 },
540 {#State 74
541 ACTIONS => {
542 'CONSTANT' => 48,
543 'TEXT' => 16,
544 'IDENTIFIER' => 26
545 },
546 DEFAULT => -97,
547 GOTOS => {
548 'identifier' => 50,
549 'anytext' => 46,
550 'text' => 51,
551 'constant' => 47,
552 'commalisttext' => 113
553 }
554 },
555 {#State 75
556 ACTIONS => {
557 'CONSTANT' => 48,
558 'TEXT' => 16,
559 'IDENTIFIER' => 26
560 },
561 DEFAULT => -97,
562 GOTOS => {
563 'identifier' => 50,
564 'anytext' => 114,
565 'text' => 51,
566 'constant' => 47
567 }
568 },
569 {#State 76
570 ACTIONS => {
571 'CONSTANT' => 48,
572 'TEXT' => 16,
573 'IDENTIFIER' => 26
574 },
575 DEFAULT => -97,
576 GOTOS => {
577 'identifier' => 50,
578 'anytext' => 115,
579 'text' => 51,
580 'constant' => 47
581 }
582 },
583 {#State 77
584 ACTIONS => {
585 'CONSTANT' => 48,
586 'TEXT' => 16,
587 'IDENTIFIER' => 26
588 },
589 DEFAULT => -97,
590 GOTOS => {
591 'identifier' => 50,
592 'anytext' => 116,
593 'text' => 51,
594 'constant' => 47
595 }
596 },
597 {#State 78
598 ACTIONS => {
599 'CONSTANT' => 48,
600 'TEXT' => 16,
601 'IDENTIFIER' => 26
602 },
603 DEFAULT => -97,
604 GOTOS => {
605 'identifier' => 50,
606 'anytext' => 46,
607 'text' => 51,
608 'constant' => 47,
609 'commalisttext' => 117
610 }
611 },
612 {#State 79
613 ACTIONS => {
614 'CONSTANT' => 48,
615 'TEXT' => 16,
616 'IDENTIFIER' => 26
617 },
618 DEFAULT => -97,
619 GOTOS => {
620 'identifier' => 50,
621 'anytext' => 118,
622 'text' => 51,
623 'constant' => 47
624 }
625 },
626 {#State 80
627 ACTIONS => {
628 'CONSTANT' => 48,
629 'TEXT' => 16,
630 'IDENTIFIER' => 26
631 },
632 DEFAULT => -97,
633 GOTOS => {
634 'identifier' => 50,
635 'anytext' => 119,
636 'text' => 51,
637 'constant' => 47
638 }
639 },
640 {#State 81
641 ACTIONS => {
642 'CONSTANT' => 48,
643 'TEXT' => 16,
644 'IDENTIFIER' => 26
645 },
646 DEFAULT => -97,
647 GOTOS => {
648 'identifier' => 50,
649 'anytext' => 120,
650 'text' => 51,
651 'constant' => 47
652 }
653 },
654 {#State 82
655 ACTIONS => {
656 'CONSTANT' => 48,
657 'TEXT' => 16,
658 'IDENTIFIER' => 26
659 },
660 DEFAULT => -97,
661 GOTOS => {
662 'identifier' => 50,
663 'anytext' => 121,
664 'text' => 51,
665 'constant' => 47
666 }
667 },
668 {#State 83
669 ACTIONS => {
670 'CONSTANT' => 48,
671 'TEXT' => 16,
672 'IDENTIFIER' => 26
673 },
674 DEFAULT => -97,
675 GOTOS => {
676 'identifier' => 50,
677 'anytext' => 122,
678 'text' => 51,
679 'constant' => 47
680 }
681 },
682 {#State 84
683 DEFAULT => -94
684 },
685 {#State 85
686 DEFAULT => -13
687 },
688 {#State 86
689 DEFAULT => -122
690 },
691 {#State 87
692 ACTIONS => {
693 ";" => 123
694 }
695 },
696 {#State 88
697 ACTIONS => {
698 ";" => 86
699 },
700 DEFAULT => -121,
701 GOTOS => {
702 'optional_semicolon' => 124
703 }
704 },
705 {#State 89
706 DEFAULT => -21
707 },
708 {#State 90
709 DEFAULT => -35
710 },
711 {#State 91
712 ACTIONS => {
713 'IDENTIFIER' => 26,
714 "signed" => 100,
715 'void' => 93,
716 "unsigned" => 104
717 },
718 DEFAULT => -89,
719 GOTOS => {
720 'existingtype' => 99,
721 'pipe' => 56,
722 'bitmap' => 57,
723 'usertype' => 95,
724 'property_list' => 94,
725 'identifier' => 96,
726 'struct' => 62,
727 'enum' => 65,
728 'type' => 125,
729 'union' => 67,
730 'sign' => 97
731 }
732 },
733 {#State 92
734 ACTIONS => {
735 'IDENTIFIER' => 126
736 },
737 DEFAULT => -117,
738 GOTOS => {
739 'optional_identifier' => 127
740 }
741 },
742 {#State 93
743 DEFAULT => -42
744 },
745 {#State 94
746 ACTIONS => {
747 "pipe" => 103,
748 "union" => 92,
749 "enum" => 101,
750 "bitmap" => 102,
751 "[" => 20,
752 "struct" => 98
753 }
754 },
755 {#State 95
756 DEFAULT => -40
757 },
758 {#State 96
759 DEFAULT => -39
760 },
761 {#State 97
762 ACTIONS => {
763 'IDENTIFIER' => 26
764 },
765 GOTOS => {
766 'identifier' => 128
767 }
768 },
769 {#State 98
770 ACTIONS => {
771 'IDENTIFIER' => 126
772 },
773 DEFAULT => -117,
774 GOTOS => {
775 'optional_identifier' => 129
776 }
777 },
778 {#State 99
779 DEFAULT => -41
780 },
781 {#State 100
782 DEFAULT => -36
783 },
784 {#State 101
785 ACTIONS => {
786 'IDENTIFIER' => 126
787 },
788 DEFAULT => -117,
789 GOTOS => {
790 'optional_identifier' => 130
791 }
792 },
793 {#State 102
794 ACTIONS => {
795 'IDENTIFIER' => 126
796 },
797 DEFAULT => -117,
798 GOTOS => {
799 'optional_identifier' => 131
800 }
801 },
802 {#State 103
803 ACTIONS => {
804 'IDENTIFIER' => 26,
805 "signed" => 100,
806 'void' => 93,
807 "unsigned" => 104
808 },
809 DEFAULT => -89,
810 GOTOS => {
811 'existingtype' => 99,
812 'pipe' => 56,
813 'bitmap' => 57,
814 'usertype' => 95,
815 'property_list' => 94,
816 'identifier' => 96,
817 'struct' => 62,
818 'enum' => 65,
819 'type' => 132,
820 'union' => 67,
821 'sign' => 97
822 }
823 },
824 {#State 104
825 DEFAULT => -37
826 },
827 {#State 105
828 ACTIONS => {
829 'IDENTIFIER' => 26
830 },
831 GOTOS => {
832 'identifier' => 133
833 }
834 },
835 {#State 106
836 DEFAULT => -75,
837 GOTOS => {
838 'pointers' => 134
839 }
840 },
841 {#State 107
842 ACTIONS => {
843 "-" => 69,
844 ":" => 68,
845 "<" => 71,
846 "+" => 73,
847 "~" => 72,
848 "*" => 80,
849 "?" => 70,
850 "{" => 74,
851 "&" => 75,
852 "/" => 76,
853 "=" => 77,
854 "(" => 78,
855 "|" => 79,
856 "." => 81,
857 ">" => 82
858 },
859 DEFAULT => -110
860 },
861 {#State 108
862 ACTIONS => {
863 ":" => 68,
864 "<" => 71,
865 "~" => 72,
866 "?" => 70,
867 "{" => 74,
868 "=" => 77
869 },
870 DEFAULT => -101
871 },
872 {#State 109
873 ACTIONS => {
874 "-" => 69,
875 ":" => 68,
876 "<" => 71,
877 "+" => 73,
878 "~" => 72,
879 "*" => 80,
880 "?" => 70,
881 "{" => 74,
882 "&" => 75,
883 "/" => 76,
884 "=" => 77,
885 "(" => 78,
886 "|" => 79,
887 "." => 81,
888 ">" => 82
889 },
890 DEFAULT => -109
891 },
892 {#State 110
893 ACTIONS => {
894 "-" => 69,
895 ":" => 68,
896 "<" => 71,
897 "+" => 73,
898 "~" => 72,
899 "*" => 80,
900 "?" => 70,
901 "{" => 74,
902 "&" => 75,
903 "/" => 76,
904 "=" => 77,
905 "(" => 78,
906 "|" => 79,
907 "." => 81,
908 ">" => 82
909 },
910 DEFAULT => -105
911 },
912 {#State 111
913 ACTIONS => {
914 "-" => 69,
915 ":" => 68,
916 "<" => 71,
917 "+" => 73,
918 "~" => 72,
919 "*" => 80,
920 "?" => 70,
921 "{" => 74,
922 "&" => 75,
923 "/" => 76,
924 "=" => 77,
925 "(" => 78,
926 "|" => 79,
927 "." => 81,
928 ">" => 82
929 },
930 DEFAULT => -113
931 },
932 {#State 112
933 ACTIONS => {
934 ":" => 68,
935 "<" => 71,
936 "~" => 72,
937 "?" => 70,
938 "{" => 74,
939 "=" => 77
940 },
941 DEFAULT => -112
942 },
943 {#State 113
944 ACTIONS => {
945 "}" => 135,
946 "," => 83
947 }
948 },
949 {#State 114
950 ACTIONS => {
951 ":" => 68,
952 "<" => 71,
953 "~" => 72,
954 "?" => 70,
955 "{" => 74,
956 "=" => 77
957 },
958 DEFAULT => -107
959 },
960 {#State 115
961 ACTIONS => {
962 ":" => 68,
963 "<" => 71,
964 "~" => 72,
965 "?" => 70,
966 "{" => 74,
967 "=" => 77
968 },
969 DEFAULT => -108
970 },
971 {#State 116
972 ACTIONS => {
973 "-" => 69,
974 ":" => 68,
975 "<" => 71,
976 "+" => 73,
977 "~" => 72,
978 "*" => 80,
979 "?" => 70,
980 "{" => 74,
981 "&" => 75,
982 "/" => 76,
983 "=" => 77,
984 "(" => 78,
985 "|" => 79,
986 "." => 81,
987 ">" => 82
988 },
989 DEFAULT => -111
990 },
991 {#State 117
992 ACTIONS => {
993 "," => 83,
994 ")" => 136
995 }
996 },
997 {#State 118
998 ACTIONS => {
999 ":" => 68,
1000 "<" => 71,
1001 "~" => 72,
1002 "?" => 70,
1003 "{" => 74,
1004 "=" => 77
1005 },
1006 DEFAULT => -106
1007 },
1008 {#State 119
1009 ACTIONS => {
1010 ":" => 68,
1011 "<" => 71,
1012 "~" => 72,
1013 "?" => 70,
1014 "{" => 74,
1015 "=" => 77
1016 },
1017 DEFAULT => -103
1018 },
1019 {#State 120
1020 ACTIONS => {
1021 ":" => 68,
1022 "<" => 71,
1023 "~" => 72,
1024 "?" => 70,
1025 "{" => 74,
1026 "=" => 77
1027 },
1028 DEFAULT => -102
1029 },
1030 {#State 121
1031 ACTIONS => {
1032 ":" => 68,
1033 "<" => 71,
1034 "~" => 72,
1035 "?" => 70,
1036 "{" => 74,
1037 "=" => 77
1038 },
1039 DEFAULT => -104
1040 },
1041 {#State 122
1042 ACTIONS => {
1043 "-" => 69,
1044 ":" => 68,
1045 "<" => 71,
1046 "+" => 73,
1047 "~" => 72,
1048 "*" => 80,
1049 "?" => 70,
1050 "{" => 74,
1051 "&" => 75,
1052 "/" => 76,
1053 "=" => 77,
1054 "(" => 78,
1055 "|" => 79,
1056 "." => 81,
1057 ">" => 82
1058 },
1059 DEFAULT => -96
1060 },
1061 {#State 123
1062 DEFAULT => -15
1063 },
1064 {#State 124
1065 DEFAULT => -16
1066 },
1067 {#State 125
1068 DEFAULT => -75,
1069 GOTOS => {
1070 'pointers' => 137
1071 }
1072 },
1073 {#State 126
1074 DEFAULT => -118
1075 },
1076 {#State 127
1077 ACTIONS => {
1078 "{" => 139
1079 },
1080 DEFAULT => -71,
1081 GOTOS => {
1082 'union_body' => 140,
1083 'opt_union_body' => 138
1084 }
1085 },
1086 {#State 128
1087 DEFAULT => -38
1088 },
1089 {#State 129
1090 ACTIONS => {
1091 "{" => 142
1092 },
1093 DEFAULT => -61,
1094 GOTOS => {
1095 'struct_body' => 141,
1096 'opt_struct_body' => 143
1097 }
1098 },
1099 {#State 130
1100 ACTIONS => {
1101 "{" => 144
1102 },
1103 DEFAULT => -44,
1104 GOTOS => {
1105 'opt_enum_body' => 146,
1106 'enum_body' => 145
1107 }
1108 },
1109 {#State 131
1110 ACTIONS => {
1111 "{" => 148
1112 },
1113 DEFAULT => -52,
1114 GOTOS => {
1115 'bitmap_body' => 149,
1116 'opt_bitmap_body' => 147
1117 }
1118 },
1119 {#State 132
1120 DEFAULT => -77
1121 },
1122 {#State 133
1123 ACTIONS => {
1124 "(" => 150
1125 }
1126 },
1127 {#State 134
1128 ACTIONS => {
1129 'IDENTIFIER' => 26,
1130 "*" => 152
1131 },
1132 GOTOS => {
1133 'identifier' => 151
1134 }
1135 },
1136 {#State 135
1137 ACTIONS => {
1138 'CONSTANT' => 48,
1139 'TEXT' => 16,
1140 'IDENTIFIER' => 26
1141 },
1142 DEFAULT => -97,
1143 GOTOS => {
1144 'identifier' => 50,
1145 'anytext' => 153,
1146 'text' => 51,
1147 'constant' => 47
1148 }
1149 },
1150 {#State 136
1151 ACTIONS => {
1152 'CONSTANT' => 48,
1153 'TEXT' => 16,
1154 'IDENTIFIER' => 26
1155 },
1156 DEFAULT => -97,
1157 GOTOS => {
1158 'identifier' => 50,
1159 'anytext' => 154,
1160 'text' => 51,
1161 'constant' => 47
1162 }
1163 },
1164 {#State 137
1165 ACTIONS => {
1166 'IDENTIFIER' => 26,
1167 "*" => 152
1168 },
1169 GOTOS => {
1170 'identifier' => 155
1171 }
1172 },
1173 {#State 138
1174 DEFAULT => -73
1175 },
1176 {#State 139
1177 DEFAULT => -68,
1178 GOTOS => {
1179 'union_elements' => 156
1180 }
1181 },
1182 {#State 140
1183 DEFAULT => -72
1184 },
1185 {#State 141
1186 DEFAULT => -62
1187 },
1188 {#State 142
1189 DEFAULT => -78,
1190 GOTOS => {
1191 'element_list1' => 157
1192 }
1193 },
1194 {#State 143
1195 DEFAULT => -63
1196 },
1197 {#State 144
1198 ACTIONS => {
1199 'IDENTIFIER' => 26
1200 },
1201 GOTOS => {
1202 'identifier' => 158,
1203 'enum_element' => 159,
1204 'enum_elements' => 160
1205 }
1206 },
1207 {#State 145
1208 DEFAULT => -45
1209 },
1210 {#State 146
1211 DEFAULT => -46
1212 },
1213 {#State 147
1214 DEFAULT => -54
1215 },
1216 {#State 148
1217 ACTIONS => {
1218 'IDENTIFIER' => 26
1219 },
1220 DEFAULT => -57,
1221 GOTOS => {
1222 'identifier' => 163,
1223 'bitmap_element' => 162,
1224 'bitmap_elements' => 161,
1225 'opt_bitmap_elements' => 164
1226 }
1227 },
1228 {#State 149
1229 DEFAULT => -53
1230 },
1231 {#State 150
1232 ACTIONS => {
1233 "," => -82,
1234 "void" => 168,
1235 "const" => 166,
1236 ")" => -82
1237 },
1238 DEFAULT => -80,
1239 GOTOS => {
1240 'optional_const' => 165,
1241 'element_list2' => 167
1242 }
1243 },
1244 {#State 151
1245 ACTIONS => {
1246 "[" => 169,
1247 "=" => 171
1248 },
1249 GOTOS => {
1250 'array_len' => 170
1251 }
1252 },
1253 {#State 152
1254 DEFAULT => -76
1255 },
1256 {#State 153
1257 ACTIONS => {
1258 "-" => 69,
1259 ":" => 68,
1260 "<" => 71,
1261 "+" => 73,
1262 "~" => 72,
1263 "*" => 80,
1264 "?" => 70,
1265 "{" => 74,
1266 "&" => 75,
1267 "/" => 76,
1268 "=" => 77,
1269 "(" => 78,
1270 "|" => 79,
1271 "." => 81,
1272 ">" => 82
1273 },
1274 DEFAULT => -115
1275 },
1276 {#State 154
1277 ACTIONS => {
1278 ":" => 68,
1279 "<" => 71,
1280 "~" => 72,
1281 "?" => 70,
1282 "{" => 74,
1283 "=" => 77
1284 },
1285 DEFAULT => -114
1286 },
1287 {#State 155
1288 ACTIONS => {
1289 "[" => 169
1290 },
1291 DEFAULT => -86,
1292 GOTOS => {
1293 'array_len' => 172
1294 }
1295 },
1296 {#State 156
1297 ACTIONS => {
1298 "}" => 173
1299 },
1300 DEFAULT => -89,
1301 GOTOS => {
1302 'optional_base_element' => 175,
1303 'property_list' => 174
1304 }
1305 },
1306 {#State 157
1307 ACTIONS => {
1308 "}" => 176
1309 },
1310 DEFAULT => -89,
1311 GOTOS => {
1312 'base_element' => 177,
1313 'property_list' => 178
1314 }
1315 },
1316 {#State 158
1317 ACTIONS => {
1318 "=" => 179
1319 },
1320 DEFAULT => -49
1321 },
1322 {#State 159
1323 DEFAULT => -47
1324 },
1325 {#State 160
1326 ACTIONS => {
1327 "}" => 180,
1328 "," => 181
1329 }
1330 },
1331 {#State 161
1332 ACTIONS => {
1333 "," => 182
1334 },
1335 DEFAULT => -58
1336 },
1337 {#State 162
1338 DEFAULT => -55
1339 },
1340 {#State 163
1341 ACTIONS => {
1342 "=" => 183
1343 }
1344 },
1345 {#State 164
1346 ACTIONS => {
1347 "}" => 184
1348 }
1349 },
1350 {#State 165
1351 DEFAULT => -89,
1352 GOTOS => {
1353 'base_element' => 185,
1354 'property_list' => 178
1355 }
1356 },
1357 {#State 166
1358 DEFAULT => -81
1359 },
1360 {#State 167
1361 ACTIONS => {
1362 "," => 186,
1363 ")" => 187
1364 }
1365 },
1366 {#State 168
1367 DEFAULT => -83
1368 },
1369 {#State 169
1370 ACTIONS => {
1371 'CONSTANT' => 48,
1372 'TEXT' => 16,
1373 "]" => 188,
1374 'IDENTIFIER' => 26
1375 },
1376 DEFAULT => -97,
1377 GOTOS => {
1378 'identifier' => 50,
1379 'anytext' => 189,
1380 'text' => 51,
1381 'constant' => 47
1382 }
1383 },
1384 {#State 170
1385 ACTIONS => {
1386 "=" => 190
1387 }
1388 },
1389 {#State 171
1390 ACTIONS => {
1391 'CONSTANT' => 48,
1392 'TEXT' => 16,
1393 'IDENTIFIER' => 26
1394 },
1395 DEFAULT => -97,
1396 GOTOS => {
1397 'identifier' => 50,
1398 'anytext' => 191,
1399 'text' => 51,
1400 'constant' => 47
1401 }
1402 },
1403 {#State 172
1404 ACTIONS => {
1405 ";" => 192
1406 }
1407 },
1408 {#State 173
1409 DEFAULT => -70
1410 },
1411 {#State 174
1412 ACTIONS => {
1413 "[" => 20
1414 },
1415 DEFAULT => -89,
1416 GOTOS => {
1417 'base_or_empty' => 193,
1418 'base_element' => 194,
1419 'empty_element' => 195,
1420 'property_list' => 196
1421 }
1422 },
1423 {#State 175
1424 DEFAULT => -69
1425 },
1426 {#State 176
1427 DEFAULT => -60
1428 },
1429 {#State 177
1430 ACTIONS => {
1431 ";" => 197
1432 }
1433 },
1434 {#State 178
1435 ACTIONS => {
1436 'IDENTIFIER' => 26,
1437 "signed" => 100,
1438 'void' => 93,
1439 "unsigned" => 104,
1440 "[" => 20
1441 },
1442 DEFAULT => -89,
1443 GOTOS => {
1444 'existingtype' => 99,
1445 'pipe' => 56,
1446 'bitmap' => 57,
1447 'usertype' => 95,
1448 'property_list' => 94,
1449 'identifier' => 96,
1450 'struct' => 62,
1451 'enum' => 65,
1452 'type' => 198,
1453 'union' => 67,
1454 'sign' => 97
1455 }
1456 },
1457 {#State 179
1458 ACTIONS => {
1459 'CONSTANT' => 48,
1460 'TEXT' => 16,
1461 'IDENTIFIER' => 26
1462 },
1463 DEFAULT => -97,
1464 GOTOS => {
1465 'identifier' => 50,
1466 'anytext' => 199,
1467 'text' => 51,
1468 'constant' => 47
1469 }
1470 },
1471 {#State 180
1472 DEFAULT => -43
1473 },
1474 {#State 181
1475 ACTIONS => {
1476 'IDENTIFIER' => 26
1477 },
1478 GOTOS => {
1479 'identifier' => 158,
1480 'enum_element' => 200
1481 }
1482 },
1483 {#State 182
1484 ACTIONS => {
1485 'IDENTIFIER' => 26
1486 },
1487 GOTOS => {
1488 'identifier' => 163,
1489 'bitmap_element' => 201
1490 }
1491 },
1492 {#State 183
1493 ACTIONS => {
1494 'CONSTANT' => 48,
1495 'TEXT' => 16,
1496 'IDENTIFIER' => 26
1497 },
1498 DEFAULT => -97,
1499 GOTOS => {
1500 'identifier' => 50,
1501 'anytext' => 202,
1502 'text' => 51,
1503 'constant' => 47
1504 }
1505 },
1506 {#State 184
1507 DEFAULT => -51
1508 },
1509 {#State 185
1510 DEFAULT => -84
1511 },
1512 {#State 186
1513 ACTIONS => {
1514 "const" => 166
1515 },
1516 DEFAULT => -80,
1517 GOTOS => {
1518 'optional_const' => 203
1519 }
1520 },
1521 {#State 187
1522 ACTIONS => {
1523 ";" => 204
1524 }
1525 },
1526 {#State 188
1527 ACTIONS => {
1528 "[" => 169
1529 },
1530 DEFAULT => -86,
1531 GOTOS => {
1532 'array_len' => 205
1533 }
1534 },
1535 {#State 189
1536 ACTIONS => {
1537 "-" => 69,
1538 ":" => 68,
1539 "?" => 70,
1540 "<" => 71,
1541 "+" => 73,
1542 "~" => 72,
1543 "&" => 75,
1544 "{" => 74,
1545 "/" => 76,
1546 "=" => 77,
1547 "|" => 79,
1548 "(" => 78,
1549 "*" => 80,
1550 "." => 81,
1551 "]" => 206,
1552 ">" => 82
1553 }
1554 },
1555 {#State 190
1556 ACTIONS => {
1557 'CONSTANT' => 48,
1558 'TEXT' => 16,
1559 'IDENTIFIER' => 26
1560 },
1561 DEFAULT => -97,
1562 GOTOS => {
1563 'identifier' => 50,
1564 'anytext' => 207,
1565 'text' => 51,
1566 'constant' => 47
1567 }
1568 },
1569 {#State 191
1570 ACTIONS => {
1571 "-" => 69,
1572 ":" => 68,
1573 "?" => 70,
1574 "<" => 71,
1575 ";" => 208,
1576 "+" => 73,
1577 "~" => 72,
1578 "&" => 75,
1579 "{" => 74,
1580 "/" => 76,
1581 "=" => 77,
1582 "|" => 79,
1583 "(" => 78,
1584 "*" => 80,
1585 "." => 81,
1586 ">" => 82
1587 }
1588 },
1589 {#State 192
1590 DEFAULT => -29
1591 },
1592 {#State 193
1593 DEFAULT => -67
1594 },
1595 {#State 194
1596 ACTIONS => {
1597 ";" => 209
1598 }
1599 },
1600 {#State 195
1601 DEFAULT => -66
1602 },
1603 {#State 196
1604 ACTIONS => {
1605 'IDENTIFIER' => 26,
1606 "signed" => 100,
1607 ";" => 210,
1608 'void' => 93,
1609 "unsigned" => 104,
1610 "[" => 20
1611 },
1612 DEFAULT => -89,
1613 GOTOS => {
1614 'existingtype' => 99,
1615 'pipe' => 56,
1616 'bitmap' => 57,
1617 'usertype' => 95,
1618 'property_list' => 94,
1619 'identifier' => 96,
1620 'struct' => 62,
1621 'enum' => 65,
1622 'type' => 198,
1623 'union' => 67,
1624 'sign' => 97
1625 }
1626 },
1627 {#State 197
1628 DEFAULT => -79
1629 },
1630 {#State 198
1631 DEFAULT => -75,
1632 GOTOS => {
1633 'pointers' => 211
1634 }
1635 },
1636 {#State 199
1637 ACTIONS => {
1638 "-" => 69,
1639 ":" => 68,
1640 "<" => 71,
1641 "+" => 73,
1642 "~" => 72,
1643 "*" => 80,
1644 "?" => 70,
1645 "{" => 74,
1646 "&" => 75,
1647 "/" => 76,
1648 "=" => 77,
1649 "(" => 78,
1650 "|" => 79,
1651 "." => 81,
1652 ">" => 82
1653 },
1654 DEFAULT => -50
1655 },
1656 {#State 200
1657 DEFAULT => -48
1658 },
1659 {#State 201
1660 DEFAULT => -56
1661 },
1662 {#State 202
1663 ACTIONS => {
1664 "-" => 69,
1665 ":" => 68,
1666 "<" => 71,
1667 "+" => 73,
1668 "~" => 72,
1669 "*" => 80,
1670 "?" => 70,
1671 "{" => 74,
1672 "&" => 75,
1673 "/" => 76,
1674 "=" => 77,
1675 "(" => 78,
1676 "|" => 79,
1677 "." => 81,
1678 ">" => 82
1679 },
1680 DEFAULT => -59
1681 },
1682 {#State 203
1683 DEFAULT => -89,
1684 GOTOS => {
1685 'base_element' => 212,
1686 'property_list' => 178
1687 }
1688 },
1689 {#State 204
1690 DEFAULT => -28
1691 },
1692 {#State 205
1693 DEFAULT => -87
1694 },
1695 {#State 206
1696 ACTIONS => {
1697 "[" => 169
1698 },
1699 DEFAULT => -86,
1700 GOTOS => {
1701 'array_len' => 213
1702 }
1703 },
1704 {#State 207
1705 ACTIONS => {
1706 "-" => 69,
1707 ":" => 68,
1708 "?" => 70,
1709 "<" => 71,
1710 ";" => 214,
1711 "+" => 73,
1712 "~" => 72,
1713 "&" => 75,
1714 "{" => 74,
1715 "/" => 76,
1716 "=" => 77,
1717 "|" => 79,
1718 "(" => 78,
1719 "*" => 80,
1720 "." => 81,
1721 ">" => 82
1722 }
1723 },
1724 {#State 208
1725 DEFAULT => -26
1726 },
1727 {#State 209
1728 DEFAULT => -65
1729 },
1730 {#State 210
1731 DEFAULT => -64
1732 },
1733 {#State 211
1734 ACTIONS => {
1735 'IDENTIFIER' => 26,
1736 "*" => 152
1737 },
1738 GOTOS => {
1739 'identifier' => 215
1740 }
1741 },
1742 {#State 212
1743 DEFAULT => -85
1744 },
1745 {#State 213
1746 DEFAULT => -88
1747 },
1748 {#State 214
1749 DEFAULT => -27
1750 },
1751 {#State 215
1752 ACTIONS => {
1753 "[" => 169
1754 },
1755 DEFAULT => -86,
1756 GOTOS => {
1757 'array_len' => 216
1758 }
1759 },
1760 {#State 216
1761 DEFAULT => -74
1762 }
1763],
1764 yyrules =>
1765[
1766 [#Rule 0
1767 '$start', 2, undef
1768 ],
1769 [#Rule 1
1770 'idl', 0, undef
1771 ],
1772 [#Rule 2
1773 'idl', 2,
1774sub
1775#line 20 "idl.yp"
1776{ push(@{$_[1]}, $_[2]); $_[1] }
1777 ],
1778 [#Rule 3
1779 'idl', 2,
1780sub
1781#line 22 "idl.yp"
1782{ push(@{$_[1]}, $_[2]); $_[1] }
1783 ],
1784 [#Rule 4
1785 'idl', 2,
1786sub
1787#line 24 "idl.yp"
1788{ push(@{$_[1]}, $_[2]); $_[1] }
1789 ],
1790 [#Rule 5
1791 'idl', 2,
1792sub
1793#line 26 "idl.yp"
1794{ push(@{$_[1]}, $_[2]); $_[1] }
1795 ],
1796 [#Rule 6
1797 'idl', 2,
1798sub
1799#line 28 "idl.yp"
1800{ push(@{$_[1]}, $_[2]); $_[1] }
1801 ],
1802 [#Rule 7
1803 'idl', 2,
1804sub
1805#line 30 "idl.yp"
1806{ push(@{$_[1]}, $_[2]); $_[1] }
1807 ],
1808 [#Rule 8
1809 'import', 3,
1810sub
1811#line 35 "idl.yp"
1812{{
1813 "TYPE" => "IMPORT",
1814 "PATHS" => $_[2],
1815 "FILE" => $_[0]->YYData->{FILE},
1816 "LINE" => $_[0]->YYData->{LINE},
1817 }}
1818 ],
1819 [#Rule 9
1820 'include', 3,
1821sub
1822#line 45 "idl.yp"
1823{{
1824 "TYPE" => "INCLUDE",
1825 "PATHS" => $_[2],
1826 "FILE" => $_[0]->YYData->{FILE},
1827 "LINE" => $_[0]->YYData->{LINE},
1828 }}
1829 ],
1830 [#Rule 10
1831 'importlib', 3,
1832sub
1833#line 55 "idl.yp"
1834{{
1835 "TYPE" => "IMPORTLIB",
1836 "PATHS" => $_[2],
1837 "FILE" => $_[0]->YYData->{FILE},
1838 "LINE" => $_[0]->YYData->{LINE},
1839 }}
1840 ],
1841 [#Rule 11
1842 'commalist', 1,
1843sub
1844#line 64 "idl.yp"
1845{ [ $_[1] ] }
1846 ],
1847 [#Rule 12
1848 'commalist', 3,
1849sub
1850#line 66 "idl.yp"
1851{ push(@{$_[1]}, $_[3]); $_[1] }
1852 ],
1853 [#Rule 13
1854 'coclass', 7,
1855sub
1856#line 71 "idl.yp"
1857{{
1858 "TYPE" => "COCLASS",
1859 "PROPERTIES" => $_[1],
1860 "NAME" => $_[3],
1861 "DATA" => $_[5],
1862 "FILE" => $_[0]->YYData->{FILE},
1863 "LINE" => $_[0]->YYData->{LINE},
1864 }}
1865 ],
1866 [#Rule 14
1867 'interface_names', 0, undef
1868 ],
1869 [#Rule 15
1870 'interface_names', 4,
1871sub
1872#line 84 "idl.yp"
1873{ push(@{$_[1]}, $_[2]); $_[1] }
1874 ],
1875 [#Rule 16
1876 'interface', 8,
1877sub
1878#line 89 "idl.yp"
1879{{
1880 "TYPE" => "INTERFACE",
1881 "PROPERTIES" => $_[1],
1882 "NAME" => $_[3],
1883 "BASE" => $_[4],
1884 "DATA" => $_[6],
1885 "FILE" => $_[0]->YYData->{FILE},
1886 "LINE" => $_[0]->YYData->{LINE},
1887 }}
1888 ],
1889 [#Rule 17
1890 'base_interface', 0, undef
1891 ],
1892 [#Rule 18
1893 'base_interface', 2,
1894sub
1895#line 103 "idl.yp"
1896{ $_[2] }
1897 ],
1898 [#Rule 19
1899 'cpp_quote', 4,
1900sub
1901#line 109 "idl.yp"
1902{{
1903 "TYPE" => "CPP_QUOTE",
1904 "DATA" => $_[3],
1905 "FILE" => $_[0]->YYData->{FILE},
1906 "LINE" => $_[0]->YYData->{LINE},
1907 }}
1908 ],
1909 [#Rule 20
1910 'definitions', 1,
1911sub
1912#line 118 "idl.yp"
1913{ [ $_[1] ] }
1914 ],
1915 [#Rule 21
1916 'definitions', 2,
1917sub
1918#line 120 "idl.yp"
1919{ push(@{$_[1]}, $_[2]); $_[1] }
1920 ],
1921 [#Rule 22
1922 'definition', 1, undef
1923 ],
1924 [#Rule 23
1925 'definition', 1, undef
1926 ],
1927 [#Rule 24
1928 'definition', 1, undef
1929 ],
1930 [#Rule 25
1931 'definition', 1, undef
1932 ],
1933 [#Rule 26
1934 'const', 7,
1935sub
1936#line 135 "idl.yp"
1937{{
1938 "TYPE" => "CONST",
1939 "DTYPE" => $_[2],
1940 "POINTERS" => $_[3],
1941 "NAME" => $_[4],
1942 "VALUE" => $_[6],
1943 "FILE" => $_[0]->YYData->{FILE},
1944 "LINE" => $_[0]->YYData->{LINE},
1945 }}
1946 ],
1947 [#Rule 27
1948 'const', 8,
1949sub
1950#line 146 "idl.yp"
1951{{
1952 "TYPE" => "CONST",
1953 "DTYPE" => $_[2],
1954 "POINTERS" => $_[3],
1955 "NAME" => $_[4],
1956 "ARRAY_LEN" => $_[5],
1957 "VALUE" => $_[7],
1958 "FILE" => $_[0]->YYData->{FILE},
1959 "LINE" => $_[0]->YYData->{LINE},
1960 }}
1961 ],
1962 [#Rule 28
1963 'function', 7,
1964sub
1965#line 160 "idl.yp"
1966{{
1967 "TYPE" => "FUNCTION",
1968 "NAME" => $_[3],
1969 "RETURN_TYPE" => $_[2],
1970 "PROPERTIES" => $_[1],
1971 "ELEMENTS" => $_[5],
1972 "FILE" => $_[0]->YYData->{FILE},
1973 "LINE" => $_[0]->YYData->{LINE},
1974 }}
1975 ],
1976 [#Rule 29
1977 'typedef', 7,
1978sub
1979#line 173 "idl.yp"
1980{{
1981 "TYPE" => "TYPEDEF",
1982 "PROPERTIES" => $_[1],
1983 "NAME" => $_[5],
1984 "DATA" => $_[3],
1985 "POINTERS" => $_[4],
1986 "ARRAY_LEN" => $_[6],
1987 "FILE" => $_[0]->YYData->{FILE},
1988 "LINE" => $_[0]->YYData->{LINE},
1989 }}
1990 ],
1991 [#Rule 30
1992 'usertype', 1, undef
1993 ],
1994 [#Rule 31
1995 'usertype', 1, undef
1996 ],
1997 [#Rule 32
1998 'usertype', 1, undef
1999 ],
2000 [#Rule 33
2001 'usertype', 1, undef
2002 ],
2003 [#Rule 34
2004 'usertype', 1, undef
2005 ],
2006 [#Rule 35
2007 'typedecl', 2,
2008sub
2009#line 198 "idl.yp"
2010{ $_[1] }
2011 ],
2012 [#Rule 36
2013 'sign', 1, undef
2014 ],
2015 [#Rule 37
2016 'sign', 1, undef
2017 ],
2018 [#Rule 38
2019 'existingtype', 2,
2020sub
2021#line 208 "idl.yp"
2022{ ($_[1]?$_[1]:"signed") ." $_[2]" }
2023 ],
2024 [#Rule 39
2025 'existingtype', 1, undef
2026 ],
2027 [#Rule 40
2028 'type', 1, undef
2029 ],
2030 [#Rule 41
2031 'type', 1, undef
2032 ],
2033 [#Rule 42
2034 'type', 1,
2035sub
2036#line 218 "idl.yp"
2037{ "void" }
2038 ],
2039 [#Rule 43
2040 'enum_body', 3,
2041sub
2042#line 222 "idl.yp"
2043{ $_[2] }
2044 ],
2045 [#Rule 44
2046 'opt_enum_body', 0, undef
2047 ],
2048 [#Rule 45
2049 'opt_enum_body', 1, undef
2050 ],
2051 [#Rule 46
2052 'enum', 4,
2053sub
2054#line 233 "idl.yp"
2055{{
2056 "TYPE" => "ENUM",
2057 "PROPERTIES" => $_[1],
2058 "NAME" => $_[3],
2059 "ELEMENTS" => $_[4],
2060 "FILE" => $_[0]->YYData->{FILE},
2061 "LINE" => $_[0]->YYData->{LINE},
2062 }}
2063 ],
2064 [#Rule 47
2065 'enum_elements', 1,
2066sub
2067#line 244 "idl.yp"
2068{ [ $_[1] ] }
2069 ],
2070 [#Rule 48
2071 'enum_elements', 3,
2072sub
2073#line 246 "idl.yp"
2074{ push(@{$_[1]}, $_[3]); $_[1] }
2075 ],
2076 [#Rule 49
2077 'enum_element', 1, undef
2078 ],
2079 [#Rule 50
2080 'enum_element', 3,
2081sub
2082#line 252 "idl.yp"
2083{ "$_[1]$_[2]$_[3]" }
2084 ],
2085 [#Rule 51
2086 'bitmap_body', 3,
2087sub
2088#line 256 "idl.yp"
2089{ $_[2] }
2090 ],
2091 [#Rule 52
2092 'opt_bitmap_body', 0, undef
2093 ],
2094 [#Rule 53
2095 'opt_bitmap_body', 1, undef
2096 ],
2097 [#Rule 54
2098 'bitmap', 4,
2099sub
2100#line 267 "idl.yp"
2101{{
2102 "TYPE" => "BITMAP",
2103 "PROPERTIES" => $_[1],
2104 "NAME" => $_[3],
2105 "ELEMENTS" => $_[4],
2106 "FILE" => $_[0]->YYData->{FILE},
2107 "LINE" => $_[0]->YYData->{LINE},
2108 }}
2109 ],
2110 [#Rule 55
2111 'bitmap_elements', 1,
2112sub
2113#line 278 "idl.yp"
2114{ [ $_[1] ] }
2115 ],
2116 [#Rule 56
2117 'bitmap_elements', 3,
2118sub
2119#line 280 "idl.yp"
2120{ push(@{$_[1]}, $_[3]); $_[1] }
2121 ],
2122 [#Rule 57
2123 'opt_bitmap_elements', 0, undef
2124 ],
2125 [#Rule 58
2126 'opt_bitmap_elements', 1, undef
2127 ],
2128 [#Rule 59
2129 'bitmap_element', 3,
2130sub
2131#line 290 "idl.yp"
2132{ "$_[1] ( $_[3] )" }
2133 ],
2134 [#Rule 60
2135 'struct_body', 3,
2136sub
2137#line 294 "idl.yp"
2138{ $_[2] }
2139 ],
2140 [#Rule 61
2141 'opt_struct_body', 0, undef
2142 ],
2143 [#Rule 62
2144 'opt_struct_body', 1, undef
2145 ],
2146 [#Rule 63
2147 'struct', 4,
2148sub
2149#line 305 "idl.yp"
2150{{
2151 "TYPE" => "STRUCT",
2152 "PROPERTIES" => $_[1],
2153 "NAME" => $_[3],
2154 "ELEMENTS" => $_[4],
2155 "FILE" => $_[0]->YYData->{FILE},
2156 "LINE" => $_[0]->YYData->{LINE},
2157 }}
2158 ],
2159 [#Rule 64
2160 'empty_element', 2,
2161sub
2162#line 317 "idl.yp"
2163{{
2164 "NAME" => "",
2165 "TYPE" => "EMPTY",
2166 "PROPERTIES" => $_[1],
2167 "POINTERS" => 0,
2168 "ARRAY_LEN" => [],
2169 "FILE" => $_[0]->YYData->{FILE},
2170 "LINE" => $_[0]->YYData->{LINE},
2171 }}
2172 ],
2173 [#Rule 65
2174 'base_or_empty', 2, undef
2175 ],
2176 [#Rule 66
2177 'base_or_empty', 1, undef
2178 ],
2179 [#Rule 67
2180 'optional_base_element', 2,
2181sub
2182#line 334 "idl.yp"
2183{ $_[2]->{PROPERTIES} = FlattenHash([$_[1],$_[2]->{PROPERTIES}]); $_[2] }
2184 ],
2185 [#Rule 68
2186 'union_elements', 0, undef
2187 ],
2188 [#Rule 69
2189 'union_elements', 2,
2190sub
2191#line 340 "idl.yp"
2192{ push(@{$_[1]}, $_[2]); $_[1] }
2193 ],
2194 [#Rule 70
2195 'union_body', 3,
2196sub
2197#line 344 "idl.yp"
2198{ $_[2] }
2199 ],
2200 [#Rule 71
2201 'opt_union_body', 0, undef
2202 ],
2203 [#Rule 72
2204 'opt_union_body', 1, undef
2205 ],
2206 [#Rule 73
2207 'union', 4,
2208sub
2209#line 355 "idl.yp"
2210{{
2211 "TYPE" => "UNION",
2212 "PROPERTIES" => $_[1],
2213 "NAME" => $_[3],
2214 "ELEMENTS" => $_[4],
2215 "FILE" => $_[0]->YYData->{FILE},
2216 "LINE" => $_[0]->YYData->{LINE},
2217 }}
2218 ],
2219 [#Rule 74
2220 'base_element', 5,
2221sub
2222#line 367 "idl.yp"
2223{{
2224 "NAME" => $_[4],
2225 "TYPE" => $_[2],
2226 "PROPERTIES" => $_[1],
2227 "POINTERS" => $_[3],
2228 "ARRAY_LEN" => $_[5],
2229 "FILE" => $_[0]->YYData->{FILE},
2230 "LINE" => $_[0]->YYData->{LINE},
2231 }}
2232 ],
2233 [#Rule 75
2234 'pointers', 0,
2235sub
2236#line 380 "idl.yp"
2237{ 0 }
2238 ],
2239 [#Rule 76
2240 'pointers', 2,
2241sub
2242#line 382 "idl.yp"
2243{ $_[1]+1 }
2244 ],
2245 [#Rule 77
2246 'pipe', 3,
2247sub
2248#line 387 "idl.yp"
2249{{
2250 "TYPE" => "PIPE",
2251 "PROPERTIES" => $_[1],
2252 "NAME" => undef,
2253 "DATA" => {
2254 "TYPE" => "STRUCT",
2255 "PROPERTIES" => $_[1],
2256 "NAME" => undef,
2257 "ELEMENTS" => [{
2258 "NAME" => "count",
2259 "PROPERTIES" => $_[1],
2260 "POINTERS" => 0,
2261 "ARRAY_LEN" => [],
2262 "TYPE" => "uint3264",
2263 "FILE" => $_[0]->YYData->{FILE},
2264 "LINE" => $_[0]->YYData->{LINE},
2265 },{
2266 "NAME" => "array",
2267 "PROPERTIES" => $_[1],
2268 "POINTERS" => 0,
2269 "ARRAY_LEN" => [ "count" ],
2270 "TYPE" => $_[3],
2271 "FILE" => $_[0]->YYData->{FILE},
2272 "LINE" => $_[0]->YYData->{LINE},
2273 }],
2274 "FILE" => $_[0]->YYData->{FILE},
2275 "LINE" => $_[0]->YYData->{LINE},
2276 },
2277 "FILE" => $_[0]->YYData->{FILE},
2278 "LINE" => $_[0]->YYData->{LINE},
2279 }}
2280 ],
2281 [#Rule 78
2282 'element_list1', 0,
2283sub
2284#line 422 "idl.yp"
2285{ [] }
2286 ],
2287 [#Rule 79
2288 'element_list1', 3,
2289sub
2290#line 424 "idl.yp"
2291{ push(@{$_[1]}, $_[2]); $_[1] }
2292 ],
2293 [#Rule 80
2294 'optional_const', 0, undef
2295 ],
2296 [#Rule 81
2297 'optional_const', 1, undef
2298 ],
2299 [#Rule 82
2300 'element_list2', 0, undef
2301 ],
2302 [#Rule 83
2303 'element_list2', 1, undef
2304 ],
2305 [#Rule 84
2306 'element_list2', 2,
2307sub
2308#line 438 "idl.yp"
2309{ [ $_[2] ] }
2310 ],
2311 [#Rule 85
2312 'element_list2', 4,
2313sub
2314#line 440 "idl.yp"
2315{ push(@{$_[1]}, $_[4]); $_[1] }
2316 ],
2317 [#Rule 86
2318 'array_len', 0, undef
2319 ],
2320 [#Rule 87
2321 'array_len', 3,
2322sub
2323#line 446 "idl.yp"
2324{ push(@{$_[3]}, "*"); $_[3] }
2325 ],
2326 [#Rule 88
2327 'array_len', 4,
2328sub
2329#line 448 "idl.yp"
2330{ push(@{$_[4]}, "$_[2]"); $_[4] }
2331 ],
2332 [#Rule 89
2333 'property_list', 0, undef
2334 ],
2335 [#Rule 90
2336 'property_list', 4,
2337sub
2338#line 454 "idl.yp"
2339{ FlattenHash([$_[1],$_[3]]); }
2340 ],
2341 [#Rule 91
2342 'properties', 1,
2343sub
2344#line 458 "idl.yp"
2345{ $_[1] }
2346 ],
2347 [#Rule 92
2348 'properties', 3,
2349sub
2350#line 460 "idl.yp"
2351{ FlattenHash([$_[1], $_[3]]); }
2352 ],
2353 [#Rule 93
2354 'property', 1,
2355sub
2356#line 464 "idl.yp"
2357{{ "$_[1]" => "1" }}
2358 ],
2359 [#Rule 94
2360 'property', 4,
2361sub
2362#line 466 "idl.yp"
2363{{ "$_[1]" => "$_[3]" }}
2364 ],
2365 [#Rule 95
2366 'commalisttext', 1, undef
2367 ],
2368 [#Rule 96
2369 'commalisttext', 3,
2370sub
2371#line 472 "idl.yp"
2372{ "$_[1],$_[3]" }
2373 ],
2374 [#Rule 97
2375 'anytext', 0,
2376sub
2377#line 477 "idl.yp"
2378{ "" }
2379 ],
2380 [#Rule 98
2381 'anytext', 1, undef
2382 ],
2383 [#Rule 99
2384 'anytext', 1, undef
2385 ],
2386 [#Rule 100
2387 'anytext', 1, undef
2388 ],
2389 [#Rule 101
2390 'anytext', 3,
2391sub
2392#line 485 "idl.yp"
2393{ "$_[1]$_[2]$_[3]" }
2394 ],
2395 [#Rule 102
2396 'anytext', 3,
2397sub
2398#line 487 "idl.yp"
2399{ "$_[1]$_[2]$_[3]" }
2400 ],
2401 [#Rule 103
2402 'anytext', 3,
2403sub
2404#line 489 "idl.yp"
2405{ "$_[1]$_[2]$_[3]" }
2406 ],
2407 [#Rule 104
2408 'anytext', 3,
2409sub
2410#line 491 "idl.yp"
2411{ "$_[1]$_[2]$_[3]" }
2412 ],
2413 [#Rule 105
2414 'anytext', 3,
2415sub
2416#line 493 "idl.yp"
2417{ "$_[1]$_[2]$_[3]" }
2418 ],
2419 [#Rule 106
2420 'anytext', 3,
2421sub
2422#line 495 "idl.yp"
2423{ "$_[1]$_[2]$_[3]" }
2424 ],
2425 [#Rule 107
2426 'anytext', 3,
2427sub
2428#line 497 "idl.yp"
2429{ "$_[1]$_[2]$_[3]" }
2430 ],
2431 [#Rule 108
2432 'anytext', 3,
2433sub
2434#line 499 "idl.yp"
2435{ "$_[1]$_[2]$_[3]" }
2436 ],
2437 [#Rule 109
2438 'anytext', 3,
2439sub
2440#line 501 "idl.yp"
2441{ "$_[1]$_[2]$_[3]" }
2442 ],
2443 [#Rule 110
2444 'anytext', 3,
2445sub
2446#line 503 "idl.yp"
2447{ "$_[1]$_[2]$_[3]" }
2448 ],
2449 [#Rule 111
2450 'anytext', 3,
2451sub
2452#line 505 "idl.yp"
2453{ "$_[1]$_[2]$_[3]" }
2454 ],
2455 [#Rule 112
2456 'anytext', 3,
2457sub
2458#line 507 "idl.yp"
2459{ "$_[1]$_[2]$_[3]" }
2460 ],
2461 [#Rule 113
2462 'anytext', 3,
2463sub
2464#line 509 "idl.yp"
2465{ "$_[1]$_[2]$_[3]" }
2466 ],
2467 [#Rule 114
2468 'anytext', 5,
2469sub
2470#line 511 "idl.yp"
2471{ "$_[1]$_[2]$_[3]$_[4]$_[5]" }
2472 ],
2473 [#Rule 115
2474 'anytext', 5,
2475sub
2476#line 513 "idl.yp"
2477{ "$_[1]$_[2]$_[3]$_[4]$_[5]" }
2478 ],
2479 [#Rule 116
2480 'identifier', 1, undef
2481 ],
2482 [#Rule 117
2483 'optional_identifier', 0, undef
2484 ],
2485 [#Rule 118
2486 'optional_identifier', 1, undef
2487 ],
2488 [#Rule 119
2489 'constant', 1, undef
2490 ],
2491 [#Rule 120
2492 'text', 1,
2493sub
2494#line 531 "idl.yp"
2495{ "\"$_[1]\"" }
2496 ],
2497 [#Rule 121
2498 'optional_semicolon', 0, undef
2499 ],
2500 [#Rule 122
2501 'optional_semicolon', 1, undef
2502 ]
2503],
2504 @_);
2505 bless($self,$class);
2506}
2507
2508#line 543 "idl.yp"
2509
2510
2511use Parse::Pidl qw(error);
2512
2513#####################################################################
2514# flatten an array of hashes into a single hash
2515sub FlattenHash($)
2516{
2517 my $a = shift;
2518 my %b;
2519 for my $d (@{$a}) {
2520 for my $k (keys %{$d}) {
2521 $b{$k} = $d->{$k};
2522 }
2523 }
2524 return \%b;
2525}
2526
2527#####################################################################
2528# traverse a perl data structure removing any empty arrays or
2529# hashes and any hash elements that map to undef
2530sub CleanData($)
2531{
2532 sub CleanData($);
2533 my($v) = shift;
2534
2535 return undef if (not defined($v));
2536
2537 if (ref($v) eq "ARRAY") {
2538 foreach my $i (0 .. $#{$v}) {
2539 CleanData($v->[$i]);
2540 }
2541 # this removes any undefined elements from the array
2542 @{$v} = grep { defined $_ } @{$v};
2543 } elsif (ref($v) eq "HASH") {
2544 foreach my $x (keys %{$v}) {
2545 CleanData($v->{$x});
2546 if (!defined $v->{$x}) {
2547 delete($v->{$x});
2548 next;
2549 }
2550 }
2551 }
2552
2553 return $v;
2554}
2555
2556sub _Error {
2557 if (exists $_[0]->YYData->{ERRMSG}) {
2558 error($_[0]->YYData, $_[0]->YYData->{ERRMSG});
2559 delete $_[0]->YYData->{ERRMSG};
2560 return;
2561 }
2562
2563 my $last_token = $_[0]->YYData->{LAST_TOKEN};
2564
2565 error($_[0]->YYData, "Syntax error near '$last_token'");
2566}
2567
2568sub _Lexer($)
2569{
2570 my($parser)=shift;
2571
2572 $parser->YYData->{INPUT} or return('',undef);
2573
2574again:
2575 $parser->YYData->{INPUT} =~ s/^[ \t]*//;
2576
2577 for ($parser->YYData->{INPUT}) {
2578 if (/^\#/) {
2579 # Linemarker format is described at
2580 # http://gcc.gnu.org/onlinedocs/cpp/Preprocessor-Output.html
2581 if (s/^\# (\d+) \"(.*?)\"(( \d+){1,4}|)//) {
2582 $parser->YYData->{LINE} = $1-1;
2583 $parser->YYData->{FILE} = $2;
2584 goto again;
2585 }
2586 if (s/^\#line (\d+) \"(.*?)\"( \d+|)//) {
2587 $parser->YYData->{LINE} = $1-1;
2588 $parser->YYData->{FILE} = $2;
2589 goto again;
2590 }
2591 if (s/^(\#.*)$//m) {
2592 goto again;
2593 }
2594 }
2595 if (s/^(\n)//) {
2596 $parser->YYData->{LINE}++;
2597 goto again;
2598 }
2599 if (s/^\"(.*?)\"//) {
2600 $parser->YYData->{LAST_TOKEN} = $1;
2601 return('TEXT',$1);
2602 }
2603 if (s/^(\d+)(\W|$)/$2/) {
2604 $parser->YYData->{LAST_TOKEN} = $1;
2605 return('CONSTANT',$1);
2606 }
2607 if (s/^([\w_]+)//) {
2608 $parser->YYData->{LAST_TOKEN} = $1;
2609 if ($1 =~
2610 /^(coclass|interface|import|importlib
2611 |include|cpp_quote|typedef
2612 |union|struct|enum|bitmap|pipe
2613 |void|const|unsigned|signed)$/x) {
2614 return $1;
2615 }
2616 return('IDENTIFIER',$1);
2617 }
2618 if (s/^(.)//s) {
2619 $parser->YYData->{LAST_TOKEN} = $1;
2620 return($1,$1);
2621 }
2622 }
2623}
2624
2625sub parse_string
2626{
2627 my ($data,$filename) = @_;
2628
2629 my $self = new Parse::Pidl::IDL;
2630
2631 $self->YYData->{FILE} = $filename;
2632 $self->YYData->{INPUT} = $data;
2633 $self->YYData->{LINE} = 0;
2634 $self->YYData->{LAST_TOKEN} = "NONE";
2635
2636 my $idl = $self->YYParse( yylex => \&_Lexer, yyerror => \&_Error );
2637
2638 return CleanData($idl);
2639}
2640
2641sub parse_file($$)
2642{
2643 my ($filename,$incdirs) = @_;
2644
2645 my $saved_delim = $/;
2646 undef $/;
2647 my $cpp = $ENV{CPP};
2648 my $options = "";
2649 if (! defined $cpp) {
2650 if (defined $ENV{CC}) {
2651 $cpp = "$ENV{CC}";
2652 $options = "-E";
2653 } else {
2654 $cpp = "cpp";
2655 }
2656 }
2657 my $includes = join('',map { " -I$_" } @$incdirs);
2658 my $data = `$cpp $options -D__PIDL__$includes -xc "$filename"`;
2659 $/ = $saved_delim;
2660
2661 return parse_string($data, $filename);
2662}
2663
26641;
Note: See TracBrowser for help on using the repository browser.