Author: tfaber
Date: Sat Dec 29 15:18:09 2012
New Revision: 58039
URL:
http://svn.reactos.org/svn/reactos?rev=58039&view=rev
Log:
[WIDL]
- Apply Wine commit "widl: Print large enum constants in hex." by Alexandre
Julliard (756d33ddae316c71b1241e7c8684c07cd82b9e05)
- Remove some minor differences to Wine
Modified:
trunk/reactos/tools/widl/header.c
trunk/reactos/tools/widl/parser.tab.c
trunk/reactos/tools/widl/parser.y
trunk/reactos/tools/widl/proxy.c
trunk/reactos/tools/widl/typegen.c
Modified: trunk/reactos/tools/widl/header.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/header.c?rev=58…
==============================================================================
--- trunk/reactos/tools/widl/header.c [iso-8859-1] (original)
+++ trunk/reactos/tools/widl/header.c [iso-8859-1] Sat Dec 29 15:18:09 2012
@@ -1223,7 +1223,8 @@
write_method_macro(header, dispinterface ? type_iface_get_inherit(iface) : iface,
iface->name);
fprintf(header, "#else\n");
write_inline_wrappers(header, dispinterface ? type_iface_get_inherit(iface) : iface,
iface->name);
- fprintf(header, "#endif\n"); fprintf(header, "#endif\n");
+ fprintf(header, "#endif\n");
+ fprintf(header, "#endif\n");
fprintf(header, "\n");
fprintf(header, "#endif\n");
fprintf(header, "\n");
Modified: trunk/reactos/tools/widl/parser.tab.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/parser.tab.c?re…
==============================================================================
--- trunk/reactos/tools/widl/parser.tab.c [iso-8859-1] (original)
+++ trunk/reactos/tools/widl/parser.tab.c [iso-8859-1] Sat Dec 29 15:18:09 2012
@@ -960,28 +960,28 @@
559, 560, 561, 562, 563, 564, 565, 566, 567, 568,
569, 570, 571, 572, 573, 574, 575, 576, 577, 578,
579, 580, 581, 585, 586, 591, 592, 593, 594, 597,
- 598, 601, 605, 611, 612, 613, 616, 620, 629, 633,
- 638, 641, 642, 645, 646, 649, 650, 651, 652, 653,
- 654, 655, 656, 657, 658, 659, 660, 661, 662, 663,
- 664, 665, 666, 667, 668, 669, 670, 671, 672, 673,
- 674, 675, 676, 677, 678, 679, 680, 681, 682, 683,
- 684, 685, 686, 688, 690, 691, 694, 695, 698, 704,
- 710, 711, 714, 719, 726, 727, 730, 731, 735, 736,
- 739, 743, 749, 757, 761, 766, 767, 770, 771, 772,
- 775, 777, 780, 781, 782, 783, 784, 785, 786, 787,
- 788, 789, 790, 793, 794, 797, 798, 799, 800, 801,
- 802, 803, 804, 807, 808, 816, 822, 826, 827, 831,
- 834, 835, 838, 847, 848, 851, 852, 855, 861, 867,
- 868, 871, 872, 875, 885, 892, 898, 902, 903, 906,
- 907, 910, 915, 922, 923, 924, 928, 932, 935, 936,
- 939, 940, 944, 945, 949, 950, 951, 955, 957, 959,
- 963, 964, 965, 966, 974, 976, 978, 983, 985, 990,
- 991, 996, 997, 998, 999, 1004, 1013, 1015, 1016, 1021,
- 1023, 1027, 1028, 1035, 1036, 1037, 1038, 1039, 1044, 1052,
- 1053, 1056, 1057, 1060, 1067, 1068, 1073, 1074, 1078, 1079,
- 1080, 1081, 1082, 1086, 1087, 1088, 1091, 1094, 1095, 1096,
- 1097, 1098, 1099, 1100, 1101, 1102, 1103, 1106, 1112, 1114,
- 1120, 1121
+ 598, 601, 605, 611, 612, 613, 616, 620, 632, 636,
+ 641, 644, 645, 648, 649, 652, 653, 654, 655, 656,
+ 657, 658, 659, 660, 661, 662, 663, 664, 665, 666,
+ 667, 668, 669, 670, 671, 672, 673, 674, 675, 676,
+ 677, 678, 679, 680, 681, 682, 683, 684, 685, 686,
+ 687, 688, 689, 691, 693, 694, 697, 698, 701, 707,
+ 713, 714, 717, 722, 729, 730, 733, 734, 738, 739,
+ 742, 746, 752, 760, 764, 769, 770, 773, 774, 775,
+ 778, 780, 783, 784, 785, 786, 787, 788, 789, 790,
+ 791, 792, 793, 796, 797, 800, 801, 802, 803, 804,
+ 805, 806, 807, 810, 811, 819, 825, 829, 830, 834,
+ 837, 838, 841, 850, 851, 854, 855, 858, 864, 870,
+ 871, 874, 875, 878, 888, 895, 901, 905, 906, 909,
+ 910, 913, 918, 925, 926, 927, 931, 935, 938, 939,
+ 942, 943, 947, 948, 952, 953, 954, 958, 960, 962,
+ 966, 967, 968, 969, 977, 979, 981, 986, 988, 993,
+ 994, 999, 1000, 1001, 1002, 1007, 1016, 1018, 1019, 1024,
+ 1026, 1030, 1031, 1038, 1039, 1040, 1041, 1042, 1047, 1055,
+ 1056, 1059, 1060, 1063, 1070, 1071, 1076, 1077, 1081, 1082,
+ 1083, 1084, 1085, 1089, 1090, 1091, 1094, 1097, 1098, 1099,
+ 1100, 1101, 1102, 1103, 1104, 1105, 1106, 1109, 1115, 1117,
+ 1123, 1124
};
#endif
@@ -4033,7 +4033,10 @@
{ if (!(yyvsp[(3) - (3)].var)->eval)
{
var_t *last = LIST_ENTRY(
list_tail((yyval.var_list)), var_t, entry );
- (yyvsp[(3) - (3)].var)->eval =
make_exprl(EXPR_NUM, last->eval->cval + 1);
+ enum expr_type type = EXPR_NUM;
+ if (last->eval->type ==
EXPR_HEXNUM) type = EXPR_HEXNUM;
+ if (last->eval->cval + 1 <
0) type = EXPR_HEXNUM;
+ (yyvsp[(3) - (3)].var)->eval =
make_exprl(type, last->eval->cval + 1);
}
(yyval.var_list) = append_var(
(yyvsp[(1) - (3)].var_list), (yyvsp[(3) - (3)].var) );
}
@@ -4042,7 +4045,7 @@
case 178:
/* Line 1806 of yacc.c */
-#line 629 "parser.y"
+#line 632 "parser.y"
{ (yyval.var) = reg_const((yyvsp[(1) - (3)].var));
(yyval.var)->eval = (yyvsp[(3) - (3)].expr);
(yyval.var)->type =
type_new_int(TYPE_BASIC_INT, 0);
@@ -4052,7 +4055,7 @@
case 179:
/* Line 1806 of yacc.c */
-#line 633 "parser.y"
+#line 636 "parser.y"
{ (yyval.var) = reg_const((yyvsp[(1) - (1)].var));
(yyval.var)->type =
type_new_int(TYPE_BASIC_INT, 0);
}
@@ -4061,336 +4064,336 @@
case 180:
/* Line 1806 of yacc.c */
-#line 638 "parser.y"
+#line 641 "parser.y"
{ (yyval.type) = type_new_enum((yyvsp[(2) - (5)].str), TRUE, (yyvsp[(4) -
(5)].var_list)); }
break;
case 181:
/* Line 1806 of yacc.c */
-#line 641 "parser.y"
+#line 644 "parser.y"
{ (yyval.expr_list) = append_expr( NULL, (yyvsp[(1) - (1)].expr) ); }
break;
case 182:
/* Line 1806 of yacc.c */
-#line 642 "parser.y"
+#line 645 "parser.y"
{ (yyval.expr_list) = append_expr( (yyvsp[(1) - (3)].expr_list), (yyvsp[(3) -
(3)].expr) ); }
break;
case 183:
/* Line 1806 of yacc.c */
-#line 645 "parser.y"
+#line 648 "parser.y"
{ (yyval.expr) = make_expr(EXPR_VOID); }
break;
case 185:
/* Line 1806 of yacc.c */
-#line 649 "parser.y"
+#line 652 "parser.y"
{ (yyval.expr) = make_exprl(EXPR_NUM, (yyvsp[(1) - (1)].num)); }
break;
case 186:
/* Line 1806 of yacc.c */
-#line 650 "parser.y"
+#line 653 "parser.y"
{ (yyval.expr) = make_exprl(EXPR_HEXNUM, (yyvsp[(1) - (1)].num)); }
break;
case 187:
/* Line 1806 of yacc.c */
-#line 651 "parser.y"
+#line 654 "parser.y"
{ (yyval.expr) = make_exprd(EXPR_DOUBLE, (yyvsp[(1) - (1)].dbl)); }
break;
case 188:
/* Line 1806 of yacc.c */
-#line 652 "parser.y"
+#line 655 "parser.y"
{ (yyval.expr) = make_exprl(EXPR_TRUEFALSE, 0); }
break;
case 189:
/* Line 1806 of yacc.c */
-#line 653 "parser.y"
+#line 656 "parser.y"
{ (yyval.expr) = make_exprl(EXPR_NUM, 0); }
break;
case 190:
/* Line 1806 of yacc.c */
-#line 654 "parser.y"
+#line 657 "parser.y"
{ (yyval.expr) = make_exprl(EXPR_TRUEFALSE, 1); }
break;
case 191:
/* Line 1806 of yacc.c */
-#line 655 "parser.y"
+#line 658 "parser.y"
{ (yyval.expr) = make_exprs(EXPR_STRLIT, (yyvsp[(1) - (1)].str)); }
break;
case 192:
/* Line 1806 of yacc.c */
-#line 656 "parser.y"
+#line 659 "parser.y"
{ (yyval.expr) = make_exprs(EXPR_WSTRLIT, (yyvsp[(1) - (1)].str)); }
break;
case 193:
/* Line 1806 of yacc.c */
-#line 657 "parser.y"
+#line 660 "parser.y"
{ (yyval.expr) = make_exprs(EXPR_CHARCONST, (yyvsp[(1) - (1)].str)); }
break;
case 194:
/* Line 1806 of yacc.c */
-#line 658 "parser.y"
+#line 661 "parser.y"
{ (yyval.expr) = make_exprs(EXPR_IDENTIFIER, (yyvsp[(1) - (1)].str)); }
break;
case 195:
/* Line 1806 of yacc.c */
-#line 659 "parser.y"
+#line 662 "parser.y"
{ (yyval.expr) = make_expr3(EXPR_COND, (yyvsp[(1) - (5)].expr), (yyvsp[(3) -
(5)].expr), (yyvsp[(5) - (5)].expr)); }
break;
case 196:
/* Line 1806 of yacc.c */
-#line 660 "parser.y"
+#line 663 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_LOGOR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 197:
/* Line 1806 of yacc.c */
-#line 661 "parser.y"
+#line 664 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_LOGAND, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 198:
/* Line 1806 of yacc.c */
-#line 662 "parser.y"
+#line 665 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_OR , (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 199:
/* Line 1806 of yacc.c */
-#line 663 "parser.y"
+#line 666 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_XOR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 200:
/* Line 1806 of yacc.c */
-#line 664 "parser.y"
+#line 667 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_AND, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 201:
/* Line 1806 of yacc.c */
-#line 665 "parser.y"
+#line 668 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_EQUALITY, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 202:
/* Line 1806 of yacc.c */
-#line 666 "parser.y"
+#line 669 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_INEQUALITY, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 203:
/* Line 1806 of yacc.c */
-#line 667 "parser.y"
+#line 670 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_GTR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 204:
/* Line 1806 of yacc.c */
-#line 668 "parser.y"
+#line 671 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_LESS, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 205:
/* Line 1806 of yacc.c */
-#line 669 "parser.y"
+#line 672 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_GTREQL, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 206:
/* Line 1806 of yacc.c */
-#line 670 "parser.y"
+#line 673 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_LESSEQL, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 207:
/* Line 1806 of yacc.c */
-#line 671 "parser.y"
+#line 674 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_SHL, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 208:
/* Line 1806 of yacc.c */
-#line 672 "parser.y"
+#line 675 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_SHR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 209:
/* Line 1806 of yacc.c */
-#line 673 "parser.y"
+#line 676 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_ADD, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 210:
/* Line 1806 of yacc.c */
-#line 674 "parser.y"
+#line 677 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_SUB, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 211:
/* Line 1806 of yacc.c */
-#line 675 "parser.y"
+#line 678 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_MOD, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 212:
/* Line 1806 of yacc.c */
-#line 676 "parser.y"
+#line 679 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_MUL, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 213:
/* Line 1806 of yacc.c */
-#line 677 "parser.y"
+#line 680 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_DIV, (yyvsp[(1) - (3)].expr), (yyvsp[(3) -
(3)].expr)); }
break;
case 214:
/* Line 1806 of yacc.c */
-#line 678 "parser.y"
+#line 681 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_LOGNOT, (yyvsp[(2) - (2)].expr)); }
break;
case 215:
/* Line 1806 of yacc.c */
-#line 679 "parser.y"
+#line 682 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_NOT, (yyvsp[(2) - (2)].expr)); }
break;
case 216:
/* Line 1806 of yacc.c */
-#line 680 "parser.y"
+#line 683 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_POS, (yyvsp[(2) - (2)].expr)); }
break;
case 217:
/* Line 1806 of yacc.c */
-#line 681 "parser.y"
+#line 684 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_NEG, (yyvsp[(2) - (2)].expr)); }
break;
case 218:
/* Line 1806 of yacc.c */
-#line 682 "parser.y"
+#line 685 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_ADDRESSOF, (yyvsp[(2) - (2)].expr)); }
break;
case 219:
/* Line 1806 of yacc.c */
-#line 683 "parser.y"
+#line 686 "parser.y"
{ (yyval.expr) = make_expr1(EXPR_PPTR, (yyvsp[(2) - (2)].expr)); }
break;
case 220:
/* Line 1806 of yacc.c */
-#line 684 "parser.y"
+#line 687 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_MEMBER, make_expr1(EXPR_PPTR, (yyvsp[(1) -
(3)].expr)), make_exprs(EXPR_IDENTIFIER, (yyvsp[(3) - (3)].str))); }
break;
case 221:
/* Line 1806 of yacc.c */
-#line 685 "parser.y"
+#line 688 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_MEMBER, (yyvsp[(1) - (3)].expr),
make_exprs(EXPR_IDENTIFIER, (yyvsp[(3) - (3)].str))); }
break;
case 222:
/* Line 1806 of yacc.c */
-#line 687 "parser.y"
+#line 690 "parser.y"
{ (yyval.expr) = make_exprt(EXPR_CAST, declare_var(NULL, (yyvsp[(2) - (5)].declspec),
(yyvsp[(3) - (5)].declarator), 0), (yyvsp[(5) - (5)].expr)); free((yyvsp[(2) -
(5)].declspec)); free((yyvsp[(3) - (5)].declarator)); }
break;
case 223:
/* Line 1806 of yacc.c */
-#line 689 "parser.y"
+#line 692 "parser.y"
{ (yyval.expr) = make_exprt(EXPR_SIZEOF, declare_var(NULL, (yyvsp[(3) -
(5)].declspec), (yyvsp[(4) - (5)].declarator), 0), NULL); free((yyvsp[(3) -
(5)].declspec)); free((yyvsp[(4) - (5)].declarator)); }
break;
case 224:
/* Line 1806 of yacc.c */
-#line 690 "parser.y"
+#line 693 "parser.y"
{ (yyval.expr) = make_expr2(EXPR_ARRAY, (yyvsp[(1) - (4)].expr), (yyvsp[(3) -
(4)].expr)); }
break;
case 225:
/* Line 1806 of yacc.c */
-#line 691 "parser.y"
+#line 694 "parser.y"
{ (yyval.expr) = (yyvsp[(2) - (3)].expr); }
break;
case 226:
/* Line 1806 of yacc.c */
-#line 694 "parser.y"
+#line 697 "parser.y"
{ (yyval.expr_list) = append_expr( NULL, (yyvsp[(1) - (1)].expr) ); }
break;
case 227:
/* Line 1806 of yacc.c */
-#line 695 "parser.y"
+#line 698 "parser.y"
{ (yyval.expr_list) = append_expr( (yyvsp[(1) - (3)].expr_list), (yyvsp[(3) -
(3)].expr) ); }
break;
case 228:
/* Line 1806 of yacc.c */
-#line 698 "parser.y"
+#line 701 "parser.y"
{ (yyval.expr) = (yyvsp[(1) - (1)].expr);
if (!(yyval.expr)->is_const)
error_loc("expression is not an integer constant\n");
@@ -4400,7 +4403,7 @@
case 229:
/* Line 1806 of yacc.c */
-#line 704 "parser.y"
+#line 707 "parser.y"
{ (yyval.expr) = (yyvsp[(1) - (1)].expr);
if (!(yyval.expr)->is_const && (yyval.expr)->type != EXPR_STRLIT
&& (yyval.expr)->type != EXPR_WSTRLIT)
error_loc("expression is not constant\n");
@@ -4410,21 +4413,21 @@
case 230:
/* Line 1806 of yacc.c */
-#line 710 "parser.y"
+#line 713 "parser.y"
{ (yyval.var_list) = NULL; }
break;
case 231:
/* Line 1806 of yacc.c */
-#line 711 "parser.y"
+#line 714 "parser.y"
{ (yyval.var_list) = append_var_list((yyvsp[(1) - (2)].var_list), (yyvsp[(2) -
(2)].var_list)); }
break;
case 232:
/* Line 1806 of yacc.c */
-#line 715 "parser.y"
+#line 718 "parser.y"
{ const char *first = LIST_ENTRY(list_head((yyvsp[(3) - (4)].declarator_list)),
declarator_t, entry)->var->name;
check_field_attrs(first, (yyvsp[(1) - (4)].attr_list));
(yyval.var_list) = set_var_types((yyvsp[(1) - (4)].attr_list), (yyvsp[(2) -
(4)].declspec), (yyvsp[(3) - (4)].declarator_list));
@@ -4434,7 +4437,7 @@
case 233:
/* Line 1806 of yacc.c */
-#line 719 "parser.y"
+#line 722 "parser.y"
{ var_t *v = make_var(NULL);
v->type = (yyvsp[(2) - (3)].type); v->attrs = (yyvsp[(1) -
(3)].attr_list);
(yyval.var_list) = append_var(NULL, v);
@@ -4444,49 +4447,49 @@
case 234:
/* Line 1806 of yacc.c */
-#line 726 "parser.y"
+#line 729 "parser.y"
{ (yyval.var) = (yyvsp[(1) - (2)].var); }
break;
case 235:
/* Line 1806 of yacc.c */
-#line 727 "parser.y"
+#line 730 "parser.y"
{ (yyval.var) = make_var(NULL); (yyval.var)->attrs = (yyvsp[(1) - (2)].attr_list);
}
break;
case 236:
/* Line 1806 of yacc.c */
-#line 730 "parser.y"
+#line 733 "parser.y"
{ (yyval.var_list) = NULL; }
break;
case 237:
/* Line 1806 of yacc.c */
-#line 731 "parser.y"
+#line 734 "parser.y"
{ (yyval.var_list) = append_var( (yyvsp[(1) - (2)].var_list), (yyvsp[(2) - (2)].var)
); }
break;
case 238:
/* Line 1806 of yacc.c */
-#line 735 "parser.y"
+#line 738 "parser.y"
{ (yyval.var) = (yyvsp[(1) - (2)].var); }
break;
case 239:
/* Line 1806 of yacc.c */
-#line 736 "parser.y"
+#line 739 "parser.y"
{ (yyval.var) = NULL; }
break;
case 240:
/* Line 1806 of yacc.c */
-#line 739 "parser.y"
+#line 742 "parser.y"
{ (yyval.var) = declare_var(check_field_attrs((yyvsp[(3) -
(3)].declarator)->var->name, (yyvsp[(1) - (3)].attr_list)),
(yyvsp[(2) - (3)].declspec), (yyvsp[(3) - (3)].declarator),
FALSE);
free((yyvsp[(3) - (3)].declarator));
@@ -4496,7 +4499,7 @@
case 241:
/* Line 1806 of yacc.c */
-#line 743 "parser.y"
+#line 746 "parser.y"
{ var_t *v = make_var(NULL);
v->type = (yyvsp[(2) - (2)].type); v->attrs = (yyvsp[(1) -
(2)].attr_list);
(yyval.var) = v;
@@ -4506,7 +4509,7 @@
case 242:
/* Line 1806 of yacc.c */
-#line 749 "parser.y"
+#line 752 "parser.y"
{ (yyval.var) = (yyvsp[(1) - (1)].var);
if (type_get_type((yyval.var)->type) != TYPE_FUNCTION)
error_loc("only methods may be declared inside the methods section of a
dispinterface\n");
@@ -4517,7 +4520,7 @@
case 243:
/* Line 1806 of yacc.c */
-#line 758 "parser.y"
+#line 761 "parser.y"
{ (yyval.var) = declare_var((yyvsp[(1) - (3)].attr_list), (yyvsp[(2) -
(3)].declspec), (yyvsp[(3) - (3)].declarator), FALSE);
free((yyvsp[(3) - (3)].declarator));
}
@@ -4526,7 +4529,7 @@
case 244:
/* Line 1806 of yacc.c */
-#line 761 "parser.y"
+#line 764 "parser.y"
{ (yyval.var) = declare_var(NULL, (yyvsp[(1) - (2)].declspec), (yyvsp[(2) -
(2)].declarator), FALSE);
free((yyvsp[(2) - (2)].declarator));
}
@@ -4535,182 +4538,182 @@
case 245:
/* Line 1806 of yacc.c */
-#line 766 "parser.y"
+#line 769 "parser.y"
{ (yyval.var) = NULL; }
break;
case 247:
/* Line 1806 of yacc.c */
-#line 770 "parser.y"
+#line 773 "parser.y"
{ (yyval.str) = NULL; }
break;
case 248:
/* Line 1806 of yacc.c */
-#line 771 "parser.y"
+#line 774 "parser.y"
{ (yyval.str) = (yyvsp[(1) - (1)].str); }
break;
case 249:
/* Line 1806 of yacc.c */
-#line 772 "parser.y"
+#line 775 "parser.y"
{ (yyval.str) = (yyvsp[(1) - (1)].str); }
break;
case 250:
/* Line 1806 of yacc.c */
-#line 775 "parser.y"
+#line 778 "parser.y"
{ (yyval.var) = make_var((yyvsp[(1) - (1)].str)); }
break;
case 251:
/* Line 1806 of yacc.c */
-#line 777 "parser.y"
+#line 780 "parser.y"
{ (yyval.var) = make_var((yyvsp[(1) - (1)].str)); }
break;
case 252:
/* Line 1806 of yacc.c */
-#line 780 "parser.y"
+#line 783 "parser.y"
{ (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
break;
case 253:
/* Line 1806 of yacc.c */
-#line 781 "parser.y"
+#line 784 "parser.y"
{ (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
break;
case 255:
/* Line 1806 of yacc.c */
-#line 783 "parser.y"
+#line 786 "parser.y"
{ (yyval.type) = type_new_int(type_basic_get_type((yyvsp[(2) - (2)].type)), -1); }
break;
case 256:
/* Line 1806 of yacc.c */
-#line 784 "parser.y"
+#line 787 "parser.y"
{ (yyval.type) = type_new_int(type_basic_get_type((yyvsp[(2) - (2)].type)), 1); }
break;
case 257:
/* Line 1806 of yacc.c */
-#line 785 "parser.y"
+#line 788 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT, 1); }
break;
case 258:
-
-/* Line 1806 of yacc.c */
-#line 786 "parser.y"
- { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
- break;
-
- case 259:
-
-/* Line 1806 of yacc.c */
-#line 787 "parser.y"
- { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
- break;
-
- case 260:
-
-/* Line 1806 of yacc.c */
-#line 788 "parser.y"
- { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
- break;
-
- case 261:
/* Line 1806 of yacc.c */
#line 789 "parser.y"
{ (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
break;
- case 262:
+ case 259:
/* Line 1806 of yacc.c */
#line 790 "parser.y"
{ (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
break;
+ case 260:
+
+/* Line 1806 of yacc.c */
+#line 791 "parser.y"
+ { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
+ break;
+
+ case 261:
+
+/* Line 1806 of yacc.c */
+#line 792 "parser.y"
+ { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
+ break;
+
+ case 262:
+
+/* Line 1806 of yacc.c */
+#line 793 "parser.y"
+ { (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
+ break;
+
case 265:
/* Line 1806 of yacc.c */
-#line 797 "parser.y"
+#line 800 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT, 0); }
break;
case 266:
/* Line 1806 of yacc.c */
-#line 798 "parser.y"
+#line 801 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT16, 0); }
break;
case 267:
/* Line 1806 of yacc.c */
-#line 799 "parser.y"
+#line 802 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT8, 0); }
break;
case 268:
/* Line 1806 of yacc.c */
-#line 800 "parser.y"
+#line 803 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT32, 0); }
break;
case 269:
/* Line 1806 of yacc.c */
-#line 801 "parser.y"
+#line 804 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_HYPER, 0); }
break;
case 270:
/* Line 1806 of yacc.c */
-#line 802 "parser.y"
+#line 805 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT64, 0); }
break;
case 271:
/* Line 1806 of yacc.c */
-#line 803 "parser.y"
+#line 806 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_CHAR, 0); }
break;
case 272:
/* Line 1806 of yacc.c */
-#line 804 "parser.y"
+#line 807 "parser.y"
{ (yyval.type) = type_new_int(TYPE_BASIC_INT3264, 0); }
break;
case 273:
/* Line 1806 of yacc.c */
-#line 807 "parser.y"
+#line 810 "parser.y"
{ (yyval.type) = type_new_coclass((yyvsp[(2) - (2)].str)); }
break;
case 274:
/* Line 1806 of yacc.c */
-#line 808 "parser.y"
+#line 811 "parser.y"
{ (yyval.type) = find_type((yyvsp[(2) - (2)].str), 0);
if (type_get_type_detect_alias((yyval.type)) != TYPE_COCLASS)
error_loc("%s was not declared a coclass at %s:%d\n",
@@ -4722,7 +4725,7 @@
case 275:
/* Line 1806 of yacc.c */
-#line 816 "parser.y"
+#line 819 "parser.y"
{ (yyval.type) = (yyvsp[(2) - (2)].type);
check_def((yyval.type));
(yyval.type)->attrs = check_coclass_attrs((yyvsp[(2) - (2)].type)->name,
(yyvsp[(1) - (2)].attr_list));
@@ -4732,49 +4735,49 @@
case 276:
/* Line 1806 of yacc.c */
-#line 823 "parser.y"
+#line 826 "parser.y"
{ (yyval.type) = type_coclass_define((yyvsp[(1) - (5)].type), (yyvsp[(3) -
(5)].ifref_list)); }
break;
case 277:
/* Line 1806 of yacc.c */
-#line 826 "parser.y"
+#line 829 "parser.y"
{ (yyval.ifref_list) = NULL; }
break;
case 278:
/* Line 1806 of yacc.c */
-#line 827 "parser.y"
+#line 830 "parser.y"
{ (yyval.ifref_list) = append_ifref( (yyvsp[(1) - (2)].ifref_list), (yyvsp[(2) -
(2)].ifref) ); }
break;
case 279:
/* Line 1806 of yacc.c */
-#line 831 "parser.y"
+#line 834 "parser.y"
{ (yyval.ifref) = make_ifref((yyvsp[(2) - (2)].type)); (yyval.ifref)->attrs =
(yyvsp[(1) - (2)].attr_list); }
break;
case 280:
/* Line 1806 of yacc.c */
-#line 834 "parser.y"
+#line 837 "parser.y"
{ (yyval.type) = get_type(TYPE_INTERFACE, (yyvsp[(2) - (2)].str), 0); }
break;
case 281:
/* Line 1806 of yacc.c */
-#line 835 "parser.y"
+#line 838 "parser.y"
{ (yyval.type) = get_type(TYPE_INTERFACE, (yyvsp[(2) - (2)].str), 0); }
break;
case 282:
/* Line 1806 of yacc.c */
-#line 838 "parser.y"
+#line 841 "parser.y"
{ attr_t *attrs;
(yyval.type) = (yyvsp[(2) - (2)].type);
check_def((yyval.type));
@@ -4787,35 +4790,35 @@
case 283:
/* Line 1806 of yacc.c */
-#line 847 "parser.y"
+#line 850 "parser.y"
{ (yyval.var_list) = NULL; }
break;
case 284:
/* Line 1806 of yacc.c */
-#line 848 "parser.y"
+#line 851 "parser.y"
{ (yyval.var_list) = append_var( (yyvsp[(1) - (3)].var_list), (yyvsp[(2) - (3)].var)
); }
break;
case 285:
/* Line 1806 of yacc.c */
-#line 851 "parser.y"
+#line 854 "parser.y"
{ (yyval.var_list) = NULL; }
break;
case 286:
/* Line 1806 of yacc.c */
-#line 852 "parser.y"
+#line 855 "parser.y"
{ (yyval.var_list) = append_var( (yyvsp[(1) - (3)].var_list), (yyvsp[(2) - (3)].var)
); }
break;
case 287:
/* Line 1806 of yacc.c */
-#line 858 "parser.y"
+#line 861 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (5)].type);
type_dispinterface_define((yyval.type), (yyvsp[(3) - (5)].var_list), (yyvsp[(4) -
(5)].var_list));
}
@@ -4824,7 +4827,7 @@
case 288:
/* Line 1806 of yacc.c */
-#line 862 "parser.y"
+#line 865 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (5)].type);
type_dispinterface_define_from_iface((yyval.type), (yyvsp[(3) - (5)].type));
}
@@ -4833,35 +4836,35 @@
case 289:
/* Line 1806 of yacc.c */
-#line 867 "parser.y"
+#line 870 "parser.y"
{ (yyval.type) = NULL; }
break;
case 290:
/* Line 1806 of yacc.c */
-#line 868 "parser.y"
+#line 871 "parser.y"
{ (yyval.type) = find_type_or_error2((yyvsp[(2) - (2)].str), 0); }
break;
case 291:
/* Line 1806 of yacc.c */
-#line 871 "parser.y"
+#line 874 "parser.y"
{ (yyval.type) = get_type(TYPE_INTERFACE, (yyvsp[(2) - (2)].str), 0); }
break;
case 292:
/* Line 1806 of yacc.c */
-#line 872 "parser.y"
+#line 875 "parser.y"
{ (yyval.type) = get_type(TYPE_INTERFACE, (yyvsp[(2) - (2)].str), 0); }
break;
case 293:
/* Line 1806 of yacc.c */
-#line 875 "parser.y"
+#line 878 "parser.y"
{ (yyval.ifinfo).interface = (yyvsp[(2) - (2)].type);
(yyval.ifinfo).old_pointer_default = pointer_default;
if (is_attr((yyvsp[(1) - (2)].attr_list), ATTR_POINTERDEFAULT))
@@ -4875,7 +4878,7 @@
case 294:
/* Line 1806 of yacc.c */
-#line 886 "parser.y"
+#line 889 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (6)].ifinfo).interface;
type_interface_define((yyval.type), (yyvsp[(2) - (6)].type), (yyvsp[(4) -
(6)].stmt_list));
pointer_default = (yyvsp[(1) - (6)].ifinfo).old_pointer_default;
@@ -4885,7 +4888,7 @@
case 295:
/* Line 1806 of yacc.c */
-#line 894 "parser.y"
+#line 897 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (8)].ifinfo).interface;
type_interface_define((yyval.type), find_type_or_error2((yyvsp[(3) - (8)].str),
0), (yyvsp[(6) - (8)].stmt_list));
pointer_default = (yyvsp[(1) - (8)].ifinfo).old_pointer_default;
@@ -4895,42 +4898,42 @@
case 296:
/* Line 1806 of yacc.c */
-#line 898 "parser.y"
+#line 901 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (2)].type); }
break;
case 297:
/* Line 1806 of yacc.c */
-#line 902 "parser.y"
+#line 905 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (2)].type); }
break;
case 298:
/* Line 1806 of yacc.c */
-#line 903 "parser.y"
+#line 906 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (2)].type); }
break;
case 299:
/* Line 1806 of yacc.c */
-#line 906 "parser.y"
+#line 909 "parser.y"
{ (yyval.type) = type_new_module((yyvsp[(2) - (2)].str)); }
break;
case 300:
/* Line 1806 of yacc.c */
-#line 907 "parser.y"
+#line 910 "parser.y"
{ (yyval.type) = type_new_module((yyvsp[(2) - (2)].str)); }
break;
case 301:
/* Line 1806 of yacc.c */
-#line 910 "parser.y"
+#line 913 "parser.y"
{ (yyval.type) = (yyvsp[(2) - (2)].type);
(yyval.type)->attrs = check_module_attrs((yyvsp[(2) - (2)].type)->name,
(yyvsp[(1) - (2)].attr_list));
}
@@ -4939,7 +4942,7 @@
case 302:
/* Line 1806 of yacc.c */
-#line 916 "parser.y"
+#line 919 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (5)].type);
type_module_define((yyval.type),
(yyvsp[(3) - (5)].stmt_list));
}
@@ -4948,105 +4951,105 @@
case 303:
/* Line 1806 of yacc.c */
-#line 922 "parser.y"
+#line 925 "parser.y"
{ (yyval.stgclass) = STG_EXTERN; }
break;
case 304:
/* Line 1806 of yacc.c */
-#line 923 "parser.y"
+#line 926 "parser.y"
{ (yyval.stgclass) = STG_STATIC; }
break;
case 305:
/* Line 1806 of yacc.c */
-#line 924 "parser.y"
+#line 927 "parser.y"
{ (yyval.stgclass) = STG_REGISTER; }
break;
case 306:
/* Line 1806 of yacc.c */
-#line 928 "parser.y"
+#line 931 "parser.y"
{ (yyval.attr) = make_attr(ATTR_INLINE); }
break;
case 307:
/* Line 1806 of yacc.c */
-#line 932 "parser.y"
+#line 935 "parser.y"
{ (yyval.attr) = make_attr(ATTR_CONST); }
break;
case 308:
/* Line 1806 of yacc.c */
-#line 935 "parser.y"
+#line 938 "parser.y"
{ (yyval.attr_list) = NULL; }
break;
case 309:
/* Line 1806 of yacc.c */
-#line 936 "parser.y"
+#line 939 "parser.y"
{ (yyval.attr_list) = append_attr((yyvsp[(1) - (2)].attr_list), (yyvsp[(2) -
(2)].attr)); }
break;
case 310:
/* Line 1806 of yacc.c */
-#line 939 "parser.y"
+#line 942 "parser.y"
{ (yyval.declspec) = make_decl_spec((yyvsp[(1) - (2)].type), (yyvsp[(2) -
(2)].declspec), NULL, NULL, STG_NONE); }
break;
case 311:
/* Line 1806 of yacc.c */
-#line 941 "parser.y"
+#line 944 "parser.y"
{ (yyval.declspec) = make_decl_spec((yyvsp[(2) - (3)].type), (yyvsp[(1) -
(3)].declspec), (yyvsp[(3) - (3)].declspec), NULL, STG_NONE); }
break;
case 312:
/* Line 1806 of yacc.c */
-#line 944 "parser.y"
+#line 947 "parser.y"
{ (yyval.declspec) = NULL; }
break;
case 314:
/* Line 1806 of yacc.c */
-#line 949 "parser.y"
+#line 952 "parser.y"
{ (yyval.declspec) = make_decl_spec(NULL, (yyvsp[(2) - (2)].declspec), NULL,
(yyvsp[(1) - (2)].attr), STG_NONE); }
break;
case 315:
/* Line 1806 of yacc.c */
-#line 950 "parser.y"
+#line 953 "parser.y"
{ (yyval.declspec) = make_decl_spec(NULL, (yyvsp[(2) - (2)].declspec), NULL,
(yyvsp[(1) - (2)].attr), STG_NONE); }
break;
case 316:
/* Line 1806 of yacc.c */
-#line 951 "parser.y"
+#line 954 "parser.y"
{ (yyval.declspec) = make_decl_spec(NULL, (yyvsp[(2) - (2)].declspec), NULL, NULL,
(yyvsp[(1) - (2)].stgclass)); }
break;
case 317:
/* Line 1806 of yacc.c */
-#line 956 "parser.y"
+#line 959 "parser.y"
{ (yyval.declarator) = (yyvsp[(3) - (3)].declarator); (yyval.declarator)->type =
append_ptrchain_type((yyval.declarator)->type, type_new_pointer(pointer_default, NULL,
(yyvsp[(2) - (3)].attr_list))); }
break;
case 318:
/* Line 1806 of yacc.c */
-#line 957 "parser.y"
+#line 960 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (2)].declarator); if
((yyval.declarator)->func_type) (yyval.declarator)->func_type->attrs =
append_attr((yyval.declarator)->func_type->attrs, make_attrp(ATTR_CALLCONV,
(yyvsp[(1) - (2)].str)));
else if ((yyval.declarator)->type)
(yyval.declarator)->type->attrs = append_attr((yyval.declarator)->type->attrs,
make_attrp(ATTR_CALLCONV, (yyvsp[(1) - (2)].str))); }
break;
@@ -5054,28 +5057,28 @@
case 320:
/* Line 1806 of yacc.c */
-#line 963 "parser.y"
+#line 966 "parser.y"
{ (yyval.declarator) = make_declarator((yyvsp[(1) - (1)].var)); }
break;
case 321:
/* Line 1806 of yacc.c */
-#line 964 "parser.y"
+#line 967 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (3)].declarator); }
break;
case 322:
/* Line 1806 of yacc.c */
-#line 965 "parser.y"
+#line 968 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (2)].declarator); (yyval.declarator)->array =
append_array((yyval.declarator)->array, (yyvsp[(2) - (2)].expr)); }
break;
case 323:
/* Line 1806 of yacc.c */
-#line 966 "parser.y"
+#line 969 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (4)].declarator);
(yyval.declarator)->func_type =
append_ptrchain_type((yyval.declarator)->type, type_new_function((yyvsp[(3) -
(4)].var_list)));
(yyval.declarator)->type = NULL;
@@ -5085,14 +5088,14 @@
case 324:
/* Line 1806 of yacc.c */
-#line 975 "parser.y"
+#line 978 "parser.y"
{ (yyval.declarator) = (yyvsp[(3) - (3)].declarator); (yyval.declarator)->type =
append_ptrchain_type((yyval.declarator)->type, type_new_pointer(pointer_default, NULL,
(yyvsp[(2) - (3)].attr_list))); }
break;
case 325:
/* Line 1806 of yacc.c */
-#line 976 "parser.y"
+#line 979 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (2)].declarator); if
((yyval.declarator)->func_type) (yyval.declarator)->func_type->attrs =
append_attr((yyval.declarator)->func_type->attrs, make_attrp(ATTR_CALLCONV,
(yyvsp[(1) - (2)].str)));
else if ((yyval.declarator)->type)
(yyval.declarator)->type->attrs = append_attr((yyval.declarator)->type->attrs,
make_attrp(ATTR_CALLCONV, (yyvsp[(1) - (2)].str))); }
break;
@@ -5100,14 +5103,14 @@
case 327:
/* Line 1806 of yacc.c */
-#line 984 "parser.y"
+#line 987 "parser.y"
{ (yyval.declarator) = (yyvsp[(3) - (3)].declarator); (yyval.declarator)->type =
append_ptrchain_type((yyval.declarator)->type, type_new_pointer(pointer_default, NULL,
(yyvsp[(2) - (3)].attr_list))); }
break;
case 328:
/* Line 1806 of yacc.c */
-#line 985 "parser.y"
+#line 988 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (2)].declarator); if
((yyval.declarator)->func_type) (yyval.declarator)->func_type->attrs =
append_attr((yyval.declarator)->func_type->attrs, make_attrp(ATTR_CALLCONV,
(yyvsp[(1) - (2)].str)));
else if ((yyval.declarator)->type)
(yyval.declarator)->type->attrs = append_attr((yyval.declarator)->type->attrs,
make_attrp(ATTR_CALLCONV, (yyvsp[(1) - (2)].str))); }
break;
@@ -5115,35 +5118,35 @@
case 329:
/* Line 1806 of yacc.c */
-#line 990 "parser.y"
+#line 993 "parser.y"
{ (yyval.declarator) = make_declarator(NULL); }
break;
case 331:
/* Line 1806 of yacc.c */
-#line 996 "parser.y"
+#line 999 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (3)].declarator); }
break;
case 332:
/* Line 1806 of yacc.c */
-#line 997 "parser.y"
+#line 1000 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (2)].declarator); (yyval.declarator)->array =
append_array((yyval.declarator)->array, (yyvsp[(2) - (2)].expr)); }
break;
case 333:
/* Line 1806 of yacc.c */
-#line 998 "parser.y"
+#line 1001 "parser.y"
{ (yyval.declarator) = make_declarator(NULL); (yyval.declarator)->array =
append_array((yyval.declarator)->array, (yyvsp[(1) - (1)].expr)); }
break;
case 334:
/* Line 1806 of yacc.c */
-#line 1000 "parser.y"
+#line 1003 "parser.y"
{ (yyval.declarator) = make_declarator(NULL);
(yyval.declarator)->func_type =
append_ptrchain_type((yyval.declarator)->type, type_new_function((yyvsp[(2) -
(3)].var_list)));
(yyval.declarator)->type = NULL;
@@ -5153,7 +5156,7 @@
case 335:
/* Line 1806 of yacc.c */
-#line 1005 "parser.y"
+#line 1008 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (4)].declarator);
(yyval.declarator)->func_type =
append_ptrchain_type((yyval.declarator)->type, type_new_function((yyvsp[(3) -
(4)].var_list)));
(yyval.declarator)->type = NULL;
@@ -5163,70 +5166,70 @@
case 336:
/* Line 1806 of yacc.c */
-#line 1014 "parser.y"
+#line 1017 "parser.y"
{ (yyval.declarator) = (yyvsp[(3) - (3)].declarator); (yyval.declarator)->type =
append_ptrchain_type((yyval.declarator)->type, type_new_pointer(pointer_default, NULL,
(yyvsp[(2) - (3)].attr_list))); }
break;
case 337:
/* Line 1806 of yacc.c */
-#line 1015 "parser.y"
+#line 1018 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (2)].declarator);
(yyval.declarator)->type->attrs = append_attr((yyval.declarator)->type->attrs,
make_attrp(ATTR_CALLCONV, (yyvsp[(1) - (2)].str))); }
break;
case 339:
/* Line 1806 of yacc.c */
-#line 1022 "parser.y"
+#line 1025 "parser.y"
{ (yyval.declarator) = (yyvsp[(3) - (3)].declarator); (yyval.declarator)->type =
append_ptrchain_type((yyval.declarator)->type, type_new_pointer(pointer_default, NULL,
(yyvsp[(2) - (3)].attr_list))); }
break;
case 340:
/* Line 1806 of yacc.c */
-#line 1023 "parser.y"
+#line 1026 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (2)].declarator);
(yyval.declarator)->type->attrs = append_attr((yyval.declarator)->type->attrs,
make_attrp(ATTR_CALLCONV, (yyvsp[(1) - (2)].str))); }
break;
case 341:
/* Line 1806 of yacc.c */
-#line 1027 "parser.y"
+#line 1030 "parser.y"
{ (yyval.declarator) = make_declarator(NULL); }
break;
case 343:
/* Line 1806 of yacc.c */
-#line 1035 "parser.y"
+#line 1038 "parser.y"
{ (yyval.declarator) = make_declarator((yyvsp[(1) - (1)].var)); }
break;
case 344:
/* Line 1806 of yacc.c */
-#line 1036 "parser.y"
+#line 1039 "parser.y"
{ (yyval.declarator) = (yyvsp[(2) - (3)].declarator); }
break;
case 345:
/* Line 1806 of yacc.c */
-#line 1037 "parser.y"
+#line 1040 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (2)].declarator); (yyval.declarator)->array =
append_array((yyval.declarator)->array, (yyvsp[(2) - (2)].expr)); }
break;
case 346:
/* Line 1806 of yacc.c */
-#line 1038 "parser.y"
+#line 1041 "parser.y"
{ (yyval.declarator) = make_declarator(NULL); (yyval.declarator)->array =
append_array((yyval.declarator)->array, (yyvsp[(1) - (1)].expr)); }
break;
case 347:
/* Line 1806 of yacc.c */
-#line 1040 "parser.y"
+#line 1043 "parser.y"
{ (yyval.declarator) = make_declarator(NULL);
(yyval.declarator)->func_type =
append_ptrchain_type((yyval.declarator)->type, type_new_function((yyvsp[(2) -
(3)].var_list)));
(yyval.declarator)->type = NULL;
@@ -5236,7 +5239,7 @@
case 348:
/* Line 1806 of yacc.c */
-#line 1045 "parser.y"
+#line 1048 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (4)].declarator);
(yyval.declarator)->func_type =
append_ptrchain_type((yyval.declarator)->type, type_new_function((yyvsp[(3) -
(4)].var_list)));
(yyval.declarator)->type = NULL;
@@ -5246,35 +5249,35 @@
case 349:
/* Line 1806 of yacc.c */
-#line 1052 "parser.y"
+#line 1055 "parser.y"
{ (yyval.declarator_list) = append_declarator( NULL, (yyvsp[(1) - (1)].declarator) );
}
break;
case 350:
/* Line 1806 of yacc.c */
-#line 1053 "parser.y"
+#line 1056 "parser.y"
{ (yyval.declarator_list) = append_declarator( (yyvsp[(1) - (3)].declarator_list),
(yyvsp[(3) - (3)].declarator) ); }
break;
case 351:
/* Line 1806 of yacc.c */
-#line 1056 "parser.y"
+#line 1059 "parser.y"
{ (yyval.expr) = NULL; }
break;
case 352:
/* Line 1806 of yacc.c */
-#line 1057 "parser.y"
+#line 1060 "parser.y"
{ (yyval.expr) = (yyvsp[(2) - (2)].expr); }
break;
case 353:
/* Line 1806 of yacc.c */
-#line 1060 "parser.y"
+#line 1063 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (2)].declarator); (yyval.declarator)->bits =
(yyvsp[(2) - (2)].expr);
if (!(yyval.declarator)->bits &&
!(yyval.declarator)->var->name)
error_loc("unnamed fields are not allowed\n");
@@ -5284,168 +5287,168 @@
case 354:
/* Line 1806 of yacc.c */
-#line 1067 "parser.y"
+#line 1070 "parser.y"
{ (yyval.declarator_list) = append_declarator( NULL, (yyvsp[(1) - (1)].declarator) );
}
break;
case 355:
/* Line 1806 of yacc.c */
-#line 1069 "parser.y"
+#line 1072 "parser.y"
{ (yyval.declarator_list) = append_declarator( (yyvsp[(1) - (3)].declarator_list),
(yyvsp[(3) - (3)].declarator) ); }
break;
case 356:
/* Line 1806 of yacc.c */
-#line 1073 "parser.y"
+#line 1076 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (1)].declarator); }
break;
case 357:
/* Line 1806 of yacc.c */
-#line 1074 "parser.y"
+#line 1077 "parser.y"
{ (yyval.declarator) = (yyvsp[(1) - (3)].declarator); (yyvsp[(1) -
(3)].declarator)->var->eval = (yyvsp[(3) - (3)].expr); }
break;
case 358:
/* Line 1806 of yacc.c */
-#line 1078 "parser.y"
+#line 1081 "parser.y"
{ (yyval.num) = THREADING_APARTMENT; }
break;
case 359:
/* Line 1806 of yacc.c */
-#line 1079 "parser.y"
+#line 1082 "parser.y"
{ (yyval.num) = THREADING_NEUTRAL; }
break;
case 360:
/* Line 1806 of yacc.c */
-#line 1080 "parser.y"
+#line 1083 "parser.y"
{ (yyval.num) = THREADING_SINGLE; }
break;
case 361:
/* Line 1806 of yacc.c */
-#line 1081 "parser.y"
+#line 1084 "parser.y"
{ (yyval.num) = THREADING_FREE; }
break;
case 362:
/* Line 1806 of yacc.c */
-#line 1082 "parser.y"
+#line 1085 "parser.y"
{ (yyval.num) = THREADING_BOTH; }
break;
case 363:
/* Line 1806 of yacc.c */
-#line 1086 "parser.y"
+#line 1089 "parser.y"
{ (yyval.num) = RPC_FC_RP; }
break;
case 364:
/* Line 1806 of yacc.c */
-#line 1087 "parser.y"
+#line 1090 "parser.y"
{ (yyval.num) = RPC_FC_UP; }
break;
case 365:
/* Line 1806 of yacc.c */
-#line 1088 "parser.y"
+#line 1091 "parser.y"
{ (yyval.num) = RPC_FC_FP; }
break;
case 366:
/* Line 1806 of yacc.c */
-#line 1091 "parser.y"
+#line 1094 "parser.y"
{ (yyval.type) = type_new_struct((yyvsp[(2) - (5)].str), TRUE, (yyvsp[(4) -
(5)].var_list)); }
break;
case 367:
/* Line 1806 of yacc.c */
-#line 1094 "parser.y"
+#line 1097 "parser.y"
{ (yyval.type) = type_new_void(); }
break;
case 368:
/* Line 1806 of yacc.c */
-#line 1095 "parser.y"
+#line 1098 "parser.y"
{ (yyval.type) = find_type_or_error((yyvsp[(1) - (1)].str), 0); }
break;
case 369:
-
-/* Line 1806 of yacc.c */
-#line 1096 "parser.y"
- { (yyval.type) = (yyvsp[(1) - (1)].type); }
- break;
-
- case 370:
-
-/* Line 1806 of yacc.c */
-#line 1097 "parser.y"
- { (yyval.type) = (yyvsp[(1) - (1)].type); }
- break;
-
- case 371:
-
-/* Line 1806 of yacc.c */
-#line 1098 "parser.y"
- { (yyval.type) = type_new_enum((yyvsp[(2) - (2)].str), FALSE, NULL); }
- break;
-
- case 372:
/* Line 1806 of yacc.c */
#line 1099 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (1)].type); }
break;
+ case 370:
+
+/* Line 1806 of yacc.c */
+#line 1100 "parser.y"
+ { (yyval.type) = (yyvsp[(1) - (1)].type); }
+ break;
+
+ case 371:
+
+/* Line 1806 of yacc.c */
+#line 1101 "parser.y"
+ { (yyval.type) = type_new_enum((yyvsp[(2) - (2)].str), FALSE, NULL); }
+ break;
+
+ case 372:
+
+/* Line 1806 of yacc.c */
+#line 1102 "parser.y"
+ { (yyval.type) = (yyvsp[(1) - (1)].type); }
+ break;
+
case 373:
/* Line 1806 of yacc.c */
-#line 1100 "parser.y"
+#line 1103 "parser.y"
{ (yyval.type) = type_new_struct((yyvsp[(2) - (2)].str), FALSE, NULL); }
break;
case 374:
/* Line 1806 of yacc.c */
-#line 1101 "parser.y"
+#line 1104 "parser.y"
{ (yyval.type) = (yyvsp[(1) - (1)].type); }
break;
case 375:
/* Line 1806 of yacc.c */
-#line 1102 "parser.y"
+#line 1105 "parser.y"
{ (yyval.type) = type_new_nonencapsulated_union((yyvsp[(2) - (2)].str), FALSE, NULL);
}
break;
case 376:
/* Line 1806 of yacc.c */
-#line 1103 "parser.y"
+#line 1106 "parser.y"
{ (yyval.type) = make_safearray((yyvsp[(3) - (4)].type)); }
break;
case 377:
/* Line 1806 of yacc.c */
-#line 1107 "parser.y"
+#line 1110 "parser.y"
{ reg_typedefs((yyvsp[(3) - (4)].declspec), (yyvsp[(4) - (4)].declarator_list),
check_typedef_attrs((yyvsp[(2) - (4)].attr_list)));
(yyval.statement) = make_statement_typedef((yyvsp[(4) - (4)].declarator_list));
}
@@ -5454,35 +5457,35 @@
case 378:
/* Line 1806 of yacc.c */
-#line 1113 "parser.y"
+#line 1116 "parser.y"
{ (yyval.type) = type_new_nonencapsulated_union((yyvsp[(2) - (5)].str), TRUE,
(yyvsp[(4) - (5)].var_list)); }
break;
case 379:
/* Line 1806 of yacc.c */
-#line 1116 "parser.y"
+#line 1119 "parser.y"
{ (yyval.type) = type_new_encapsulated_union((yyvsp[(2) - (10)].str), (yyvsp[(5) -
(10)].var), (yyvsp[(7) - (10)].var), (yyvsp[(9) - (10)].var_list)); }
break;
case 380:
/* Line 1806 of yacc.c */
-#line 1120 "parser.y"
+#line 1123 "parser.y"
{ (yyval.num) = MAKEVERSION((yyvsp[(1) - (1)].num), 0); }
break;
case 381:
/* Line 1806 of yacc.c */
-#line 1121 "parser.y"
+#line 1124 "parser.y"
{ (yyval.num) = MAKEVERSION((yyvsp[(1) - (3)].num), (yyvsp[(3) - (3)].num)); }
break;
/* Line 1806 of yacc.c */
-#line 5486 "parser.tab.c"
+#line 5489 "parser.tab.c"
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
@@ -5713,7 +5716,7 @@
/* Line 2067 of yacc.c */
-#line 1124 "parser.y"
+#line 1127 "parser.y"
static void decl_builtin_basic(const char *name, enum type_basic_type type)
Modified: trunk/reactos/tools/widl/parser.y
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/parser.y?rev=58…
==============================================================================
--- trunk/reactos/tools/widl/parser.y [iso-8859-1] (original)
+++ trunk/reactos/tools/widl/parser.y [iso-8859-1] Sat Dec 29 15:18:09 2012
@@ -620,7 +620,10 @@
| enum_list ',' enum { if (!$3->eval)
{
var_t *last = LIST_ENTRY(
list_tail($$), var_t, entry );
- $3->eval = make_exprl(EXPR_NUM,
last->eval->cval + 1);
+ enum expr_type type = EXPR_NUM;
+ if (last->eval->type ==
EXPR_HEXNUM) type = EXPR_HEXNUM;
+ if (last->eval->cval + 1 <
0) type = EXPR_HEXNUM;
+ $3->eval = make_exprl(type,
last->eval->cval + 1);
}
$$ = append_var( $1, $3 );
}
Modified: trunk/reactos/tools/widl/proxy.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/proxy.c?rev=580…
==============================================================================
--- trunk/reactos/tools/widl/proxy.c [iso-8859-1] (original)
+++ trunk/reactos/tools/widl/proxy.c [iso-8859-1] Sat Dec 29 15:18:09 2012
@@ -787,7 +787,7 @@
int need_proxy_file(const statement_list_t *stmts)
{
- return does_any_iface(stmts, need_proxy);
+ return does_any_iface(stmts, need_proxy);
}
int need_inline_stubs(const type_t *iface)
Modified: trunk/reactos/tools/widl/typegen.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/typegen.c?rev=5…
==============================================================================
--- trunk/reactos/tools/widl/typegen.c [iso-8859-1] (original)
+++ trunk/reactos/tools/widl/typegen.c [iso-8859-1] Sat Dec 29 15:18:09 2012
@@ -2344,7 +2344,6 @@
}
}
write_member_type(file, type, cont_is_complex, NULL, elem, NULL, tfsoff);
- return;
}
static void write_end(FILE *file, unsigned int *tfsoff)