47 #define YYBISON_VERSION "3.0.4" 50 #define YYSKELETON_NAME "yacc.c" 81 #define GDB_YY_REMAP_PREFIX rust 84 #define RUSTSTYPE YYSTYPE 130 unsigned int n_supers);
187 "[0-9][0-9_]*\\.[0-9][0-9_]*([eE][-+]?[0-9][0-9_]*)?(f32|f64)?" 188 #define FLOAT_TYPE1 3 194 #define FLOAT_TYPE2 4 195 "[0-9][0-9_]*[eE][-+]?[0-9][0-9_]*(f32|f64)?" 209 "(0x[a-fA-F0-9_]+|0o[0-7_]+|0b[01_]+|[0-9][0-9_]*)" 210 "([iu](size|8|16|32|64))?" 214 #define NUM_SUBEXPRESSIONS 8 252 set_vectors.push_back (std::unique_ptr<rust_set_vector> (result));
261 op_vectors.push_back (std::unique_ptr<rust_op_vector> (result));
292 #line 293 "rust-exp.c" 294 # ifndef YY_NULLPTRPTR 295 # if defined __cplusplus && 201103L <= __cplusplus 296 # define YY_NULLPTRPTR nullptr 298 # define YY_NULLPTRPTR 0 303 #ifdef YYERROR_VERBOSE 304 # undef YYERROR_VERBOSE 305 # define YYERROR_VERBOSE 1 307 # define YYERROR_VERBOSE 0 363 #define DECIMAL_INTEGER 262 365 #define BYTESTRING 264 367 #define COMPOUND_ASSIGN 266 375 #define KW_EXTERN 274 378 #define KW_SIZEOF 277 388 #define COLONCOLON 287 393 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED 397 #line 250 "rust-exp.y" 428 #line 429 "rust-exp.c" 432 # define YYSTYPE_IS_TRIVIAL 1 433 # define YYSTYPE_IS_DECLARED 1 444 #line 281 "rust-exp.y" 474 #line 475 "rust-exp.c" 505 # ifdef __SIZE_TYPE__ 506 # define YYSIZE_T __SIZE_TYPE__ 507 # elif defined size_t 508 # define YYSIZE_T size_t 509 # elif ! defined YYSIZE_T 511 # define YYSIZE_T size_t 513 # define YYSIZE_T unsigned int 517 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) 520 # if defined YYENABLE_NLS && YYENABLE_NLS 522 # include <libintl.h> 523 # define YY_(Msgid) dgettext ("bison-runtime", Msgid) 527 # define YY_(Msgid) Msgid 532 # if (defined __GNUC__ \ 533 && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ 534 || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C 535 # define YY_ATTRIBUTE(Spec) __attribute__(Spec) 537 # define YY_ATTRIBUTE(Spec) 541 #ifndef YY_ATTRIBUTE_PURE 542 # define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) 545 #ifndef YY_ATTRIBUTE_UNUSED 546 # define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) 549 #if !defined _Noreturn \ 550 && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) 551 # if defined _MSC_VER && 1200 <= _MSC_VER 552 # define _Noreturn __declspec (noreturn) 554 # define _Noreturn YY_ATTRIBUTE ((__noreturn__)) 559 #if ! defined lint || defined __GNUC__ 560 # define YYUSE(E) ((void) (E)) 565 #if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ 567 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ 568 _Pragma ("GCC diagnostic push") \ 569 _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ 570 _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") 571 # define YY_IGNORE_MAYBE_UNINITIALIZED_END \ 572 _Pragma ("GCC diagnostic pop") 574 # define YY_INITIAL_VALUE(Value) Value 576 #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 577 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 578 # define YY_IGNORE_MAYBE_UNINITIALIZED_END 580 #ifndef YY_INITIAL_VALUE 581 # define YY_INITIAL_VALUE(Value) 585 #if ! defined yyoverflow || YYERROR_VERBOSE 589 # ifdef YYSTACK_USE_ALLOCA 590 # if YYSTACK_USE_ALLOCA 592 # define YYSTACK_ALLOC __builtin_alloca 593 # elif defined __BUILTIN_VA_ARG_INCR 596 # define YYSTACK_ALLOC __alloca 597 # elif defined _MSC_VER 598 # define alloca _alloca 600 # define YYSTACK_ALLOC alloca 601 # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS 604 # ifndef EXIT_SUCCESS 605 # define EXIT_SUCCESS 0 612 # ifdef YYSTACK_ALLOC 614 # define YYSTACK_FREE(Ptr) do { ; } while (0) 615 # ifndef YYSTACK_ALLOC_MAXIMUM 620 # define YYSTACK_ALLOC_MAXIMUM 4032 623 # define YYSTACK_ALLOC YYMALLOC 624 # define YYSTACK_FREE YYFREE 625 # ifndef YYSTACK_ALLOC_MAXIMUM 626 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM 628 # if (defined __cplusplus && ! defined EXIT_SUCCESS \ 629 && ! ((defined YYMALLOC || defined xmalloc) \ 630 && (defined YYFREE || defined xfree))) 632 # ifndef EXIT_SUCCESS 633 # define EXIT_SUCCESS 0 637 # define YYMALLOC xmalloc 638 # if ! defined xmalloc && ! defined EXIT_SUCCESS 643 # define YYFREE xfree 644 # if ! defined xfree && ! defined EXIT_SUCCESS 652 #if (! defined yyoverflow \ 653 && (! defined __cplusplus \ 654 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) 664 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) 668 # define YYSTACK_BYTES(N) \ 669 ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ 670 + YYSTACK_GAP_MAXIMUM) 672 # define YYCOPY_NEEDED 1 679 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \ 682 YYSIZE_T yynewbytes; \ 683 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ 684 Stack = &yyptr->Stack_alloc; \ 685 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ 686 yyptr += yynewbytes / sizeof (*yyptr); \ 692 #if defined YYCOPY_NEEDED && YYCOPY_NEEDED 696 # if defined __GNUC__ && 1 < __GNUC__ 697 # define YYCOPY(Dst, Src, Count) \ 698 __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src))) 700 # define YYCOPY(Dst, Src, Count) \ 704 for (yyi = 0; yyi < (Count); yyi++) \ 705 (Dst)[yyi] = (Src)[yyi]; \ 724 #define YYNSTATES 213 729 #define YYMAXUTOK 289 731 #define YYTRANSLATE(YYX) \ 732 ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) 738 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
739 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
740 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
741 2, 2, 2, 57, 2, 2, 2, 45, 39, 2,
742 49, 51, 43, 41, 50, 42, 48, 44, 2, 2,
743 2, 2, 2, 2, 2, 2, 2, 2, 54, 56,
744 35, 34, 36, 2, 40, 2, 2, 2, 2, 2,
745 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
746 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
747 2, 47, 2, 55, 38, 2, 2, 2, 2, 2,
748 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
749 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
750 2, 2, 2, 52, 37, 53, 2, 2, 2, 2,
751 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
752 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
753 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
754 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
755 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
756 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
757 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
758 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
759 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
760 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
761 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
762 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
763 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
764 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
765 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
766 25, 26, 27, 28, 29, 30, 31, 32, 33, 46
773 0, 406, 406, 419, 420, 421, 422, 423, 424, 425,
774 426, 427, 428, 429, 430, 431, 435, 443, 460, 465,
775 475, 487, 490, 496, 508, 510, 512, 514, 519, 521,
776 523, 525, 530, 532, 534, 536, 563, 565, 574, 586,
777 588, 593, 598, 603, 606, 609, 618, 621, 624, 626,
778 631, 632, 633, 634, 638, 641, 644, 647, 650, 653,
779 656, 659, 662, 665, 668, 671, 674, 677, 680, 683,
780 686, 689, 692, 697, 702, 707, 713, 718, 723, 732,
781 736, 741, 748, 752, 754, 758, 760, 765, 767, 769,
782 774, 775, 777, 779, 781, 793, 795, 801, 803, 811,
783 812, 814, 816, 818, 830, 832, 841, 842, 844, 852,
784 853, 855, 857, 859, 861, 863, 865, 867, 873, 874,
789 #if YYDEBUG || YYERROR_VERBOSE || 0 794 "$end",
"error",
"$undefined",
"GDBVAR",
"IDENT",
"COMPLETE",
"INTEGER",
795 "DECIMAL_INTEGER",
"STRING",
"BYTESTRING",
"FLOAT",
"COMPOUND_ASSIGN",
796 "KW_AS",
"KW_IF",
"KW_TRUE",
"KW_FALSE",
"KW_SUPER",
"KW_SELF",
"KW_MUT",
797 "KW_EXTERN",
"KW_CONST",
"KW_FN",
"KW_SIZEOF",
"DOTDOT",
"OROR",
798 "ANDAND",
"EQEQ",
"NOTEQ",
"LTEQ",
"GTEQ",
"LSH",
"RSH",
"COLONCOLON",
799 "ARROW",
"'='",
"'<'",
"'>'",
"'|'",
"'^'",
"'&'",
"'@'",
"'+'",
"'-'",
800 "'*'",
"'/'",
"'%'",
"UNARY",
"'['",
"'.'",
"'('",
"','",
"')'",
"'{'",
801 "'}'",
"':'",
"']'",
"';'",
"'!'",
"$accept",
"start",
"expr",
802 "tuple_expr",
"unit_expr",
"struct_expr",
"struct_expr_tail",
803 "struct_expr_list",
"array_expr",
"range_expr",
"literal",
"field_expr",
804 "idx_expr",
"unop_expr",
"binop_expr",
"binop_expr_expr",
805 "type_cast_expr",
"assignment_expr",
"compound_assignment_expr",
806 "paren_expr",
"expr_list",
"maybe_expr_list",
"paren_expr_list",
807 "call_expr",
"maybe_self_path",
"super_path",
"path_expr",
808 "path_for_expr",
"identifier_path_for_expr",
"path_for_type",
809 "just_identifiers_for_type",
"identifier_path_for_type",
"type",
819 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
820 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
821 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
822 285, 286, 287, 288, 61, 60, 62, 124, 94, 38,
823 64, 43, 45, 42, 47, 37, 289, 91, 46, 40,
824 44, 41, 123, 125, 58, 93, 59, 33
828 #define YYPACT_NINF -151 830 #define yypact_value_is_default(Yystate) \ 831 (!!((Yystate) == (-151))) 833 #define YYTABLE_NINF -119 835 #define yytable_value_is_error(Yytable_value) \ 836 (!!((Yytable_value) == (-119))) 842 384, -151, -151, -151, -151, -151, -151, -151, -151, -151,
843 -20, 41, -2, 119, 41, 176, 384, 384, 384, 228,
844 280, 384, 56, 742, -151, -151, -151, -151, -151, -151,
845 -151, -151, -151, -151, -151, -151, -151, -151, -151, -151,
846 42, -151, 8, 30, 41, 30, 384, 781, 30, 384,
847 68, 68, 68, 68, 384, 425, -28, -151, 620, 68,
848 -151, 384, 209, 119, 384, 384, 384, 384, 384, 384,
849 384, 384, 384, 384, 384, 384, 384, 384, 384, 384,
850 384, 384, 384, 384, 384, 96, 332, -151, 53, 10,
851 6, 5, 30, 661, 68, 464, 2, 384, 384, -151,
852 332, -151, 820, -151, 78, 109, 71, 109, 261, 15,
853 209, 396, 42, -151, 73, -151, -151, 781, 854, 888,
854 922, 922, 922, 922, 162, 162, 820, 922, 922, 942,
855 962, 982, 47, 313, 313, -11, -11, -11, 503, -151,
856 -151, -151, 742, 74, 70, -151, 98, 30, 77, 384,
857 -151, 86, -151, 209, -151, 384, -151, 542, 742, 89,
858 109, -151, 396, -151, 209, -151, 209, 209, 87, -151,
859 93, 95, 27, 142, 209, -151, -151, -151, 384, 742,
860 -151, -8, 581, -151, -151, -151, 99, -50, -151, -151,
861 112, -151, 209, -151, -151, -6, 702, -151, -151, -151,
862 114, -151, 97, 101, -151, -151, -151, 6, 209, -151,
871 83, 88, 95, 32, 33, 35, 36, 34, 37, 38,
872 89, 0, 0, 31, 0, 83, 83, 83, 83, 83,
873 83, 83, 0, 2, 5, 6, 7, 9, 11, 3,
874 8, 10, 12, 13, 50, 51, 52, 53, 14, 15,
875 0, 4, 87, 90, 84, 94, 83, 30, 93, 83,
876 47, 43, 44, 46, 83, 77, 0, 17, 0, 45,
877 1, 83, 83, 28, 83, 83, 83, 83, 83, 83,
878 83, 83, 83, 83, 83, 83, 83, 83, 83, 83,
879 83, 83, 83, 83, 83, 0, 79, 82, 0, 0,
880 21, 0, 91, 0, 48, 77, 0, 83, 83, 25,
881 79, 76, 75, 104, 0, 0, 0, 0, 83, 0,
882 83, 83, 0, 109, 106, 99, 73, 29, 65, 66,
883 67, 68, 69, 70, 71, 72, 74, 58, 59, 61,
884 62, 60, 55, 63, 64, 54, 56, 57, 0, 39,
885 40, 41, 77, 80, 0, 85, 0, 92, 0, 83,
886 22, 0, 96, 83, 49, 83, 24, 0, 78, 0,
887 84, 103, 83, 102, 83, 113, 83, 83, 0, 120,
888 0, 119, 0, 0, 83, 42, 81, 86, 83, 19,
889 18, 0, 0, 27, 16, 100, 0, 0, 114, 115,
890 0, 117, 83, 101, 105, 0, 20, 98, 97, 26,
891 0, 112, 0, 0, 121, 108, 107, 21, 83, 110,
898 -151, -151, 0, -151, -151, -151, -151, -53, -151, -151,
899 -151, -151, -151, -151, -151, -151, -151, -151, -151, -151,
900 -15, 57, -151, -151, -60, 51, -151, -151, -3, -151,
901 -151, -73, -55, 3, -150
907 -1, 22, 142, 24, 25, 26, 150, 151, 27, 28,
908 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
909 143, 144, 87, 39, 40, 89, 41, 42, 43, 113,
910 114, 115, 169, 170, 171
918 23, 62, 112, 181, 56, 201, 190, 116, 45, 152,
919 148, 48, 44, 47, 2, 50, 51, 52, 53, 55,
920 58, 59, 98, 197, 195, 205, 146, 99, 198, 149,
921 206, 103, 161, 166, 163, 167, 84, 85, 86, 96,
922 153, 92, 192, 146, 192, 2, 93, 46, 112, 94,
923 112, 112, 98, 165, 95, 168, 60, 156, 88, 62,
924 90, 102, 91, 117, 118, 119, 120, 121, 122, 123,
925 124, 125, 126, 127, 128, 129, 130, 131, 132, 133,
926 134, 135, 136, 137, 138, 145, 147, 185, 79, 80,
927 81, 82, 83, 112, 84, 85, 86, 157, 158, 193,
928 139, 140, 112, 141, 112, 173, 112, 112, 174, 187,
929 160, 188, 189, 103, 112, 84, 85, 86, 202, 203,
930 162, 176, 1, 2, 98, 3, 4, 5, 6, 7,
931 177, 178, 112, 8, 9, -83, 10, 204, 11, 180,
932 184, 12, -119, 190, 191, 192, 194, 208, 112, 179,
933 200, 14, 209, 212, 211, 182, 210, 159, 15, 0,
934 16, 17, 18, 172, 0, 186, 19, 0, 20, 0,
935 0, 0, 0, 0, 62, 0, 21, 0, 196, 1,
936 2, 0, 3, 4, 5, 6, 7, 0, 0, 0,
937 8, 9, 0, 10, 49, 11, 0, 0, 12, 13,
938 0, 0, 78, 79, 80, 81, 82, 83, 14, 84,
939 85, 86, 0, 103, 0, 15, 0, 16, 17, 18,
940 0, 0, 0, 19, 0, 20, 104, 0, 105, 0,
941 106, 1, 2, 21, 3, 4, 5, 6, 7, 0,
942 0, 107, 8, 9, 0, 10, 54, 11, 108, 0,
943 12, 13, 109, 0, 0, 0, 110, 0, 111, 0,
944 14, 0, 0, 0, 0, 103, 0, 15, 0, 16,
945 17, 18, 0, 0, 0, 19, 0, 20, 104, 0,
946 105, 0, 106, 1, 2, 21, 3, 4, 5, 6,
947 7, 0, 0, 107, 8, 9, 0, 10, 0, 11,
948 108, 0, 12, 13, 109, 0, 0, 0, 164, 0,
949 111, 0, 14, 0, 0, 0, 0, 0, 0, 15,
950 0, 16, 17, 18, 0, 62, 0, 19, 0, 20,
951 0, 57, 0, 0, 0, 1, 2, 21, 3, 4,
952 5, 6, 7, 0, 0, 0, 8, 9, -83, 10,
953 0, 11, 0, 0, 12, 13, 81, 82, 83, 0,
954 84, 85, 86, 0, 14, 0, 0, 0, 0, 0,
955 0, 15, 0, 16, 17, 18, 0, 0, 0, 19,
956 0, 20, 0, 0, 0, 0, 0, 1, 2, 21,
957 3, 4, 5, 6, 7, 0, 0, 0, 8, 9,
958 103, 10, 0, 11, 0, 0, 12, 13, 0, 0,
959 0, 0, 0, 104, 0, 105, 14, 106, 0, 0,
960 0, 0, 0, 15, 0, 16, 17, 18, 107, 0,
961 0, 19, 0, 20, 0, 108, 61, 62, 0, 109,
962 0, 21, 0, 110, 0, 111, 0, -118, 63, 64,
963 65, 66, 67, 68, 69, 70, 71, 0, 0, 72,
964 73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
965 83, 0, 84, 85, 86, 61, 62, 0, 0, 0,
966 0, 97, 0, 0, 0, 0, 0, 63, 64, 65,
967 66, 67, 68, 69, 70, 71, 0, 0, 72, 73,
968 74, 75, 76, 77, 78, 79, 80, 81, 82, 83,
969 0, 84, 85, 86, 61, 62, 0, 0, 0, 0,
970 155, 0, 0, 0, 0, 0, 63, 64, 65, 66,
971 67, 68, 69, 70, 71, 0, 0, 72, 73, 74,
972 75, 76, 77, 78, 79, 80, 81, 82, 83, 0,
973 84, 85, 86, 61, 62, 0, 0, 0, 175, 0,
974 0, 0, 0, 0, 0, 63, 64, 65, 66, 67,
975 68, 69, 70, 71, 0, 0, 72, 73, 74, 75,
976 76, 77, 78, 79, 80, 81, 82, 83, 0, 84,
977 85, 86, 61, 62, 0, 0, 0, 183, 0, 0,
978 0, 0, 0, 0, 63, 64, 65, 66, 67, 68,
979 69, 70, 71, 0, 0, 72, 73, 74, 75, 76,
980 77, 78, 79, 80, 81, 82, 83, 0, 84, 85,
981 86, 61, 62, 0, 0, 0, 199, 0, 0, 0,
982 0, 0, 0, 63, 64, 65, 66, 67, 68, 69,
983 70, 71, 0, 0, 72, 73, 74, 75, 76, 77,
984 78, 79, 80, 81, 82, 83, 0, 84, 85, 86,
985 100, 101, 61, 62, 0, 0, 0, 0, 0, 0,
986 0, 0, 0, 0, 63, 64, 65, 66, 67, 68,
987 69, 70, 71, 0, 0, 72, 73, 74, 75, 76,
988 77, 78, 79, 80, 81, 82, 83, 0, 84, 85,
989 86, 0, 154, 61, 62, 0, 0, 0, 0, 0,
990 0, 0, 0, 0, 0, 63, 64, 65, 66, 67,
991 68, 69, 70, 71, 0, 0, 72, 73, 74, 75,
992 76, 77, 78, 79, 80, 81, 82, 83, 0, 84,
993 85, 86, 207, 61, 62, 0, 0, 0, 0, 0,
994 0, 0, 0, 0, 0, 63, 64, 65, 66, 67,
995 68, 69, 70, 71, 0, 0, 72, 73, 74, 75,
996 76, 77, 78, 79, 80, 81, 82, 83, 0, 84,
997 85, 86, 61, 62, 0, 0, 0, 0, 0, 0,
998 0, 0, 0, 0, -119, 64, 65, 66, 67, 68,
999 69, 70, 71, 0, 0, 72, 73, 74, 75, 76,
1000 77, 78, 79, 80, 81, 82, 83, 0, 84, 85,
1001 86, 61, 62, 0, 0, 0, 0, 0, 0, 0,
1002 0, 0, 0, 0, 64, 65, 66, 67, 68, 69,
1003 70, 71, 0, 0, 72, 73, 74, 75, 76, 77,
1004 78, 79, 80, 81, 82, 83, 62, 84, 85, 86,
1005 0, 0, 0, 0, 0, 0, 0, 0, 0, 65,
1006 66, 67, 68, 69, 70, 71, 0, 0, 0, 73,
1007 74, 75, 76, 77, 78, 79, 80, 81, 82, 83,
1008 62, 84, 85, 86, 0, 0, 0, 0, 0, 0,
1009 0, 0, 0, 0, 66, 67, 68, 69, 70, 71,
1010 0, 0, 0, 73, 74, 75, 76, 77, 78, 79,
1011 80, 81, 82, 83, 62, 84, 85, 86, 0, 0,
1012 0, 0, 0, 0, 0, 0, 0, 0, -119, -119,
1013 -119, -119, 70, 71, 62, 0, 0, -119, -119, 75,
1014 76, 77, 78, 79, 80, 81, 82, 83, 0, 84,
1015 85, 86, 70, 71, 62, 0, 0, 0, 0, 0,
1016 76, 77, 78, 79, 80, 81, 82, 83, 0, 84,
1017 85, 86, 70, 71, 62, 0, 0, 0, 0, 0,
1018 0, 77, 78, 79, 80, 81, 82, 83, 0, 84,
1019 85, 86, 70, 71, 0, 0, 0, 0, 0, 0,
1020 0, 0, 78, 79, 80, 81, 82, 83, 0, 84,
1026 0, 12, 62, 153, 19, 55, 56, 62, 11, 4,
1027 4, 14, 32, 13, 4, 15, 16, 17, 18, 19,
1028 20, 21, 50, 31, 174, 31, 16, 55, 36, 23,
1029 36, 4, 105, 18, 107, 20, 47, 48, 49, 54,
1030 35, 44, 50, 16, 50, 4, 46, 49, 108, 49,
1031 110, 111, 50, 108, 54, 110, 0, 55, 16, 12,
1032 52, 61, 32, 63, 64, 65, 66, 67, 68, 69,
1033 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
1034 80, 81, 82, 83, 84, 32, 89, 160, 41, 42,
1035 43, 44, 45, 153, 47, 48, 49, 97, 98, 172,
1036 4, 5, 162, 7, 164, 32, 166, 167, 35, 164,
1037 32, 166, 167, 4, 174, 47, 48, 49, 6, 7,
1038 49, 51, 3, 4, 50, 6, 7, 8, 9, 10,
1039 32, 54, 192, 14, 15, 16, 17, 192, 19, 53,
1040 51, 22, 23, 56, 51, 50, 4, 33, 208, 149,
1041 51, 32, 55, 208, 207, 155, 55, 100, 39, -1,
1042 41, 42, 43, 112, -1, 162, 47, -1, 49, -1,
1043 -1, -1, -1, -1, 12, -1, 57, -1, 178, 3,
1044 4, -1, 6, 7, 8, 9, 10, -1, -1, -1,
1045 14, 15, -1, 17, 18, 19, -1, -1, 22, 23,
1046 -1, -1, 40, 41, 42, 43, 44, 45, 32, 47,
1047 48, 49, -1, 4, -1, 39, -1, 41, 42, 43,
1048 -1, -1, -1, 47, -1, 49, 17, -1, 19, -1,
1049 21, 3, 4, 57, 6, 7, 8, 9, 10, -1,
1050 -1, 32, 14, 15, -1, 17, 18, 19, 39, -1,
1051 22, 23, 43, -1, -1, -1, 47, -1, 49, -1,
1052 32, -1, -1, -1, -1, 4, -1, 39, -1, 41,
1053 42, 43, -1, -1, -1, 47, -1, 49, 17, -1,
1054 19, -1, 21, 3, 4, 57, 6, 7, 8, 9,
1055 10, -1, -1, 32, 14, 15, -1, 17, -1, 19,
1056 39, -1, 22, 23, 43, -1, -1, -1, 47, -1,
1057 49, -1, 32, -1, -1, -1, -1, -1, -1, 39,
1058 -1, 41, 42, 43, -1, 12, -1, 47, -1, 49,
1059 -1, 51, -1, -1, -1, 3, 4, 57, 6, 7,
1060 8, 9, 10, -1, -1, -1, 14, 15, 16, 17,
1061 -1, 19, -1, -1, 22, 23, 43, 44, 45, -1,
1062 47, 48, 49, -1, 32, -1, -1, -1, -1, -1,
1063 -1, 39, -1, 41, 42, 43, -1, -1, -1, 47,
1064 -1, 49, -1, -1, -1, -1, -1, 3, 4, 57,
1065 6, 7, 8, 9, 10, -1, -1, -1, 14, 15,
1066 4, 17, -1, 19, -1, -1, 22, 23, -1, -1,
1067 -1, -1, -1, 17, -1, 19, 32, 21, -1, -1,
1068 -1, -1, -1, 39, -1, 41, 42, 43, 32, -1,
1069 -1, 47, -1, 49, -1, 39, 11, 12, -1, 43,
1070 -1, 57, -1, 47, -1, 49, -1, 51, 23, 24,
1071 25, 26, 27, 28, 29, 30, 31, -1, -1, 34,
1072 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
1073 45, -1, 47, 48, 49, 11, 12, -1, -1, -1,
1074 -1, 56, -1, -1, -1, -1, -1, 23, 24, 25,
1075 26, 27, 28, 29, 30, 31, -1, -1, 34, 35,
1076 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
1077 -1, 47, 48, 49, 11, 12, -1, -1, -1, -1,
1078 56, -1, -1, -1, -1, -1, 23, 24, 25, 26,
1079 27, 28, 29, 30, 31, -1, -1, 34, 35, 36,
1080 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
1081 47, 48, 49, 11, 12, -1, -1, -1, 55, -1,
1082 -1, -1, -1, -1, -1, 23, 24, 25, 26, 27,
1083 28, 29, 30, 31, -1, -1, 34, 35, 36, 37,
1084 38, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1085 48, 49, 11, 12, -1, -1, -1, 55, -1, -1,
1086 -1, -1, -1, -1, 23, 24, 25, 26, 27, 28,
1087 29, 30, 31, -1, -1, 34, 35, 36, 37, 38,
1088 39, 40, 41, 42, 43, 44, 45, -1, 47, 48,
1089 49, 11, 12, -1, -1, -1, 55, -1, -1, -1,
1090 -1, -1, -1, 23, 24, 25, 26, 27, 28, 29,
1091 30, 31, -1, -1, 34, 35, 36, 37, 38, 39,
1092 40, 41, 42, 43, 44, 45, -1, 47, 48, 49,
1093 50, 51, 11, 12, -1, -1, -1, -1, -1, -1,
1094 -1, -1, -1, -1, 23, 24, 25, 26, 27, 28,
1095 29, 30, 31, -1, -1, 34, 35, 36, 37, 38,
1096 39, 40, 41, 42, 43, 44, 45, -1, 47, 48,
1097 49, -1, 51, 11, 12, -1, -1, -1, -1, -1,
1098 -1, -1, -1, -1, -1, 23, 24, 25, 26, 27,
1099 28, 29, 30, 31, -1, -1, 34, 35, 36, 37,
1100 38, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1101 48, 49, 50, 11, 12, -1, -1, -1, -1, -1,
1102 -1, -1, -1, -1, -1, 23, 24, 25, 26, 27,
1103 28, 29, 30, 31, -1, -1, 34, 35, 36, 37,
1104 38, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1105 48, 49, 11, 12, -1, -1, -1, -1, -1, -1,
1106 -1, -1, -1, -1, 23, 24, 25, 26, 27, 28,
1107 29, 30, 31, -1, -1, 34, 35, 36, 37, 38,
1108 39, 40, 41, 42, 43, 44, 45, -1, 47, 48,
1109 49, 11, 12, -1, -1, -1, -1, -1, -1, -1,
1110 -1, -1, -1, -1, 24, 25, 26, 27, 28, 29,
1111 30, 31, -1, -1, 34, 35, 36, 37, 38, 39,
1112 40, 41, 42, 43, 44, 45, 12, 47, 48, 49,
1113 -1, -1, -1, -1, -1, -1, -1, -1, -1, 25,
1114 26, 27, 28, 29, 30, 31, -1, -1, -1, 35,
1115 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
1116 12, 47, 48, 49, -1, -1, -1, -1, -1, -1,
1117 -1, -1, -1, -1, 26, 27, 28, 29, 30, 31,
1118 -1, -1, -1, 35, 36, 37, 38, 39, 40, 41,
1119 42, 43, 44, 45, 12, 47, 48, 49, -1, -1,
1120 -1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
1121 28, 29, 30, 31, 12, -1, -1, 35, 36, 37,
1122 38, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1123 48, 49, 30, 31, 12, -1, -1, -1, -1, -1,
1124 38, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1125 48, 49, 30, 31, 12, -1, -1, -1, -1, -1,
1126 -1, 39, 40, 41, 42, 43, 44, 45, -1, 47,
1127 48, 49, 30, 31, -1, -1, -1, -1, -1, -1,
1128 -1, -1, 40, 41, 42, 43, 44, 45, -1, 47,
1136 0, 3, 4, 6, 7, 8, 9, 10, 14, 15,
1137 17, 19, 22, 23, 32, 39, 41, 42, 43, 47,
1138 49, 57, 59, 60, 61, 62, 63, 66, 67, 68,
1139 69, 70, 71, 72, 73, 74, 75, 76, 77, 81,
1140 82, 84, 85, 86, 32, 86, 49, 60, 86, 18,
1141 60, 60, 60, 60, 18, 60, 78, 51, 60, 60,
1142 0, 11, 12, 23, 24, 25, 26, 27, 28, 29,
1143 30, 31, 34, 35, 36, 37, 38, 39, 40, 41,
1144 42, 43, 44, 45, 47, 48, 49, 80, 16, 83,
1145 52, 32, 86, 60, 60, 60, 78, 56, 50, 55,
1146 50, 51, 60, 4, 17, 19, 21, 32, 39, 43,
1147 47, 49, 82, 87, 88, 89, 90, 60, 60, 60,
1148 60, 60, 60, 60, 60, 60, 60, 60, 60, 60,
1149 60, 60, 60, 60, 60, 60, 60, 60, 60, 4,
1150 5, 7, 60, 78, 79, 32, 16, 86, 4, 23,
1151 64, 65, 4, 35, 51, 56, 55, 60, 60, 79,
1152 32, 89, 49, 89, 47, 90, 18, 20, 90, 90,
1153 91, 92, 83, 32, 35, 55, 51, 32, 54, 60,
1154 53, 92, 60, 55, 51, 89, 91, 90, 90, 90,
1155 56, 51, 50, 89, 4, 92, 60, 31, 36, 55,
1156 51, 55, 6, 7, 90, 31, 36, 50, 33, 55,
1163 0, 58, 59, 60, 60, 60, 60, 60, 60, 60,
1164 60, 60, 60, 60, 60, 60, 61, 62, 63, 64,
1165 64, 65, 65, 65, 66, 66, 66, 66, 67, 67,
1166 67, 67, 68, 68, 68, 68, 68, 68, 68, 69,
1167 69, 69, 70, 71, 71, 71, 71, 71, 71, 71,
1168 72, 72, 72, 72, 73, 73, 73, 73, 73, 73,
1169 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
1170 73, 73, 73, 74, 75, 76, 77, 78, 78, 79,
1171 79, 80, 81, 82, 82, 83, 83, 84, 84, 84,
1172 85, 85, 85, 85, 85, 86, 86, 86, 86, 87,
1173 87, 87, 87, 87, 88, 88, 89, 89, 89, 90,
1174 90, 90, 90, 90, 90, 90, 90, 90, 91, 91,
1181 0, 2, 1, 1, 1, 1, 1, 1, 1, 1,
1182 1, 1, 1, 1, 1, 1, 5, 2, 4, 2,
1183 3, 0, 1, 5, 4, 3, 6, 5, 2, 3,
1184 2, 1, 1, 1, 1, 1, 1, 1, 1, 3,
1185 3, 3, 4, 2, 2, 2, 2, 2, 3, 4,
1186 1, 1, 1, 1, 3, 3, 3, 3, 3, 3,
1187 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
1188 3, 3, 3, 3, 3, 3, 3, 1, 3, 0,
1189 1, 3, 2, 0, 2, 2, 3, 1, 1, 1,
1190 1, 3, 3, 2, 2, 1, 3, 5, 5, 1,
1191 3, 3, 2, 2, 1, 3, 1, 4, 4, 1,
1192 5, 5, 4, 2, 3, 3, 6, 3, 0, 1,
1197 #define yyerrok (yyerrstatus = 0) 1198 #define yyclearin (yychar = YYEMPTY) 1199 #define YYEMPTY (-2) 1202 #define YYACCEPT goto yyacceptlab 1203 #define YYABORT goto yyabortlab 1204 #define YYERROR goto yyerrorlab 1207 #define YYRECOVERING() (!!yyerrstatus) 1209 #define YYBACKUP(Token, Value) \ 1211 if (yychar == YYEMPTY) \ 1215 YYPOPSTACK (yylen); \ 1221 yyerror (YY_("syntax error: cannot back up")); \ 1228 #define YYERRCODE 256 1237 # define YYFPRINTF fprintf 1240 # define YYDPRINTF(Args) \ 1247 #ifndef YY_LOCATION_PRINT 1248 # define YY_LOCATION_PRINT(File, Loc) ((void) 0) 1252 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ 1256 YYFPRINTF (stderr, "%s ", Title); \ 1257 yy_symbol_print (stderr, \ 1259 YYFPRINTF (stderr, "\n"); \ 1271 FILE *yyo = yyoutput;
1306 for (; yybottom <= yytop; yybottom++)
1308 int yybot = *yybottom;
1314 # define YY_STACK_PRINT(Bottom, Top) \ 1317 yy_stack_print ((Bottom), (Top)); \ 1331 YYFPRINTF (stderr,
"Reducing stack by rule %d (line %lu):\n",
1334 for (yyi = 0; yyi < yynrhs; yyi++)
1339 &(
yyvsp[(yyi + 1) - (yynrhs)])
1345 # define YY_REDUCE_PRINT(Rule) \ 1348 yy_reduce_print (yyssp, yyvsp, Rule); \ 1355 # define YYDPRINTF(Args) 1356 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) 1357 # define YY_STACK_PRINT(Bottom, Top) 1358 # define YY_REDUCE_PRINT(Rule) 1364 # define YYINITDEPTH 200 1375 # define YYMAXDEPTH 10000 1382 # if defined __GLIBC__ && defined _STRING_H 1383 # define yystrlen strlen 1387 yystrlen (
const char *yystr)
1398 # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE 1399 # define yystpcpy stpcpy 1404 yystpcpy (
char *yydest,
const char *yysrc)
1407 const char *
yys = yysrc;
1409 while ((*yyd++ = *
yys++) !=
'\0')
1426 yytnamerr (
char *yyres,
const char *yystr)
1431 char const *yyp = yystr;
1438 goto do_not_strip_quotes;
1442 goto do_not_strip_quotes;
1455 do_not_strip_quotes: ;
1459 return yystrlen (yystr);
1461 return yystpcpy (yyres, yystr) - yyres;
1474 yysyntax_error (
YYSIZE_T *yymsg_alloc,
char **yymsg,
1479 enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
1483 char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
1514 yyarg[yycount++] =
yytname[yytoken];
1520 int yyxbegin = yyn < 0 ? -yyn : 0;
1522 int yychecklim =
YYLAST - yyn + 1;
1526 for (yyx = yyxbegin; yyx < yyxend; ++yyx)
1530 if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
1536 yyarg[yycount++] =
yytname[yyx];
1539 if (! (yysize <= yysize1
1550 # define YYCASE_(N, S) \ 1554 YYCASE_(0,
YY_(
"syntax error"));
1555 YYCASE_(1,
YY_(
"syntax error, unexpected %s"));
1556 YYCASE_(2,
YY_(
"syntax error, unexpected %s, expecting %s"));
1557 YYCASE_(3,
YY_(
"syntax error, unexpected %s, expecting %s or %s"));
1558 YYCASE_(4,
YY_(
"syntax error, unexpected %s, expecting %s or %s or %s"));
1559 YYCASE_(5,
YY_(
"syntax error, unexpected %s, expecting %s or %s or %s or %s"));
1564 YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
1570 if (*yymsg_alloc < yysize)
1572 *yymsg_alloc = 2 * yysize;
1573 if (! (yysize <= *yymsg_alloc
1585 while ((*yyp = *yyformat) !=
'\0')
1586 if (*yyp ==
'%' && yyformat[1] ==
's' && yyi < yycount)
1588 yyp += yytnamerr (yyp, yyarg[yyi++]);
1671 char *yymsg = yymsgbuf;
1672 YYSIZE_T yymsg_alloc =
sizeof yymsgbuf;
1675 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) 1685 YYDPRINTF ((stderr,
"Starting parse\n"));
1721 yyoverflow (
YY_(
"memory exhausted"),
1722 &yyss1, yysize *
sizeof (*
yyssp),
1723 &yyvs1, yysize *
sizeof (*
yyvsp),
1730 # ifndef YYSTACK_RELOCATE 1731 goto yyexhaustedlab;
1735 goto yyexhaustedlab;
1745 goto yyexhaustedlab;
1748 # undef YYSTACK_RELOCATE 1758 YYDPRINTF ((stderr,
"Stack size increased to %lu\n",
1790 YYDPRINTF ((stderr,
"Reading a token: "));
1797 YYDPRINTF ((stderr,
"Now at end of input.\n"));
1870 #line 407 "rust-exp.y" 1877 #line 1879 "rust-exp.c" 1881 #line 436 "rust-exp.y" 1883 (
yyvsp[-1].params)->push_back ((
yyvsp[-3].op));
1884 error (
_(
"Tuple expressions not supported yet"));
1886 #line 1888 "rust-exp.c" 1890 #line 444 "rust-exp.y" 1901 #line 1903 "rust-exp.c" 1905 #line 461 "rust-exp.y" 1907 #line 1909 "rust-exp.c" 1911 #line 466 "rust-exp.y" 1919 (
yyval.one_field_init) = sf;
1921 #line 1923 "rust-exp.c" 1925 #line 476 "rust-exp.y" 1931 (
yyval.one_field_init) = sf;
1933 #line 1935 "rust-exp.c" 1937 #line 487 "rust-exp.y" 1941 #line 1943 "rust-exp.c" 1945 #line 491 "rust-exp.y" 1948 result->push_back ((
yyvsp[0].one_field_init));
1949 (
yyval.field_inits) = result;
1951 #line 1953 "rust-exp.c" 1955 #line 497 "rust-exp.y" 1961 (
yyvsp[0].field_inits)->push_back (sf);
1962 (
yyval.field_inits) = (
yyvsp[0].field_inits);
1964 #line 1966 "rust-exp.c" 1968 #line 509 "rust-exp.y" 1970 #line 1972 "rust-exp.c" 1974 #line 511 "rust-exp.y" 1976 #line 1978 "rust-exp.c" 1980 #line 513 "rust-exp.y" 1982 #line 1984 "rust-exp.c" 1986 #line 515 "rust-exp.y" 1988 #line 1990 "rust-exp.c" 1992 #line 520 "rust-exp.y" 1994 #line 1996 "rust-exp.c" 1998 #line 522 "rust-exp.y" 2000 #line 2002 "rust-exp.c" 2004 #line 524 "rust-exp.y" 2006 #line 2008 "rust-exp.c" 2010 #line 526 "rust-exp.y" 2012 #line 2014 "rust-exp.c" 2016 #line 531 "rust-exp.y" 2018 #line 2020 "rust-exp.c" 2022 #line 533 "rust-exp.y" 2024 #line 2026 "rust-exp.c" 2028 #line 535 "rust-exp.y" 2030 #line 2032 "rust-exp.c" 2034 #line 537 "rust-exp.y" 2047 fields->push_back (
field);
2055 fields->push_back (
field);
2061 #line 2063 "rust-exp.c" 2065 #line 564 "rust-exp.y" 2067 #line 2069 "rust-exp.c" 2071 #line 566 "rust-exp.y" 2080 #line 2082 "rust-exp.c" 2084 #line 575 "rust-exp.y" 2093 #line 2095 "rust-exp.c" 2097 #line 587 "rust-exp.y" 2099 #line 2101 "rust-exp.c" 2103 #line 589 "rust-exp.y" 2108 #line 2110 "rust-exp.c" 2112 #line 594 "rust-exp.y" 2114 #line 2116 "rust-exp.c" 2118 #line 599 "rust-exp.y" 2120 #line 2122 "rust-exp.c" 2124 #line 604 "rust-exp.y" 2126 #line 2128 "rust-exp.c" 2130 #line 607 "rust-exp.y" 2132 #line 2134 "rust-exp.c" 2136 #line 610 "rust-exp.y" 2144 #line 2146 "rust-exp.c" 2148 #line 619 "rust-exp.y" 2150 #line 2152 "rust-exp.c" 2154 #line 622 "rust-exp.y" 2156 #line 2158 "rust-exp.c" 2160 #line 625 "rust-exp.y" 2162 #line 2164 "rust-exp.c" 2166 #line 627 "rust-exp.y" 2168 #line 2170 "rust-exp.c" 2172 #line 639 "rust-exp.y" 2174 #line 2176 "rust-exp.c" 2178 #line 642 "rust-exp.y" 2180 #line 2182 "rust-exp.c" 2184 #line 645 "rust-exp.y" 2186 #line 2188 "rust-exp.c" 2190 #line 648 "rust-exp.y" 2192 #line 2194 "rust-exp.c" 2196 #line 651 "rust-exp.y" 2198 #line 2200 "rust-exp.c" 2202 #line 654 "rust-exp.y" 2204 #line 2206 "rust-exp.c" 2208 #line 657 "rust-exp.y" 2210 #line 2212 "rust-exp.c" 2214 #line 660 "rust-exp.y" 2216 #line 2218 "rust-exp.c" 2220 #line 663 "rust-exp.y" 2222 #line 2224 "rust-exp.c" 2226 #line 666 "rust-exp.y" 2228 #line 2230 "rust-exp.c" 2232 #line 669 "rust-exp.y" 2234 #line 2236 "rust-exp.c" 2238 #line 672 "rust-exp.y" 2240 #line 2242 "rust-exp.c" 2244 #line 675 "rust-exp.y" 2246 #line 2248 "rust-exp.c" 2250 #line 678 "rust-exp.y" 2252 #line 2254 "rust-exp.c" 2256 #line 681 "rust-exp.y" 2258 #line 2260 "rust-exp.c" 2262 #line 684 "rust-exp.y" 2264 #line 2266 "rust-exp.c" 2268 #line 687 "rust-exp.y" 2270 #line 2272 "rust-exp.c" 2274 #line 690 "rust-exp.y" 2276 #line 2278 "rust-exp.c" 2280 #line 693 "rust-exp.y" 2282 #line 2284 "rust-exp.c" 2286 #line 698 "rust-exp.y" 2288 #line 2290 "rust-exp.c" 2292 #line 703 "rust-exp.y" 2294 #line 2296 "rust-exp.c" 2298 #line 708 "rust-exp.y" 2300 #line 2302 "rust-exp.c" 2304 #line 714 "rust-exp.y" 2306 #line 2308 "rust-exp.c" 2310 #line 719 "rust-exp.y" 2315 #line 2317 "rust-exp.c" 2319 #line 724 "rust-exp.y" 2321 (
yyvsp[-2].params)->push_back ((
yyvsp[0].op));
2324 #line 2326 "rust-exp.c" 2328 #line 732 "rust-exp.y" 2333 #line 2335 "rust-exp.c" 2337 #line 737 "rust-exp.y" 2339 #line 2341 "rust-exp.c" 2343 #line 744 "rust-exp.y" 2345 #line 2347 "rust-exp.c" 2349 #line 749 "rust-exp.y" 2351 #line 2353 "rust-exp.c" 2355 #line 759 "rust-exp.y" 2356 { (
yyval.depth) = 1; }
2357 #line 2359 "rust-exp.c" 2361 #line 761 "rust-exp.y" 2363 #line 2365 "rust-exp.c" 2367 #line 766 "rust-exp.y" 2369 #line 2371 "rust-exp.c" 2373 #line 768 "rust-exp.y" 2375 #line 2377 "rust-exp.c" 2379 #line 770 "rust-exp.y" 2381 #line 2383 "rust-exp.c" 2385 #line 776 "rust-exp.y" 2387 #line 2389 "rust-exp.c" 2391 #line 778 "rust-exp.y" 2393 #line 2395 "rust-exp.c" 2397 #line 780 "rust-exp.y" 2399 #line 2401 "rust-exp.c" 2403 #line 782 "rust-exp.y" 2410 (
yyvsp[0].op)->right.params);
2412 #line 2414 "rust-exp.c" 2416 #line 794 "rust-exp.y" 2418 #line 2420 "rust-exp.c" 2422 #line 796 "rust-exp.y" 2425 (
yyvsp[0].sval).ptr),
2428 #line 2430 "rust-exp.c" 2432 #line 802 "rust-exp.y" 2434 #line 2436 "rust-exp.c" 2438 #line 804 "rust-exp.y" 2443 #line 2445 "rust-exp.c" 2447 #line 813 "rust-exp.y" 2449 #line 2451 "rust-exp.c" 2453 #line 815 "rust-exp.y" 2455 #line 2457 "rust-exp.c" 2459 #line 817 "rust-exp.y" 2461 #line 2463 "rust-exp.c" 2465 #line 819 "rust-exp.y" 2472 (
yyvsp[0].op)->right.params);
2474 #line 2476 "rust-exp.c" 2478 #line 831 "rust-exp.y" 2480 #line 2482 "rust-exp.c" 2484 #line 833 "rust-exp.y" 2487 (
yyvsp[0].sval).ptr),
2490 #line 2492 "rust-exp.c" 2494 #line 843 "rust-exp.y" 2496 #line 2498 "rust-exp.c" 2500 #line 845 "rust-exp.y" 2505 #line 2507 "rust-exp.c" 2509 #line 854 "rust-exp.y" 2511 #line 2513 "rust-exp.c" 2515 #line 856 "rust-exp.y" 2517 #line 2519 "rust-exp.c" 2521 #line 858 "rust-exp.y" 2523 #line 2525 "rust-exp.c" 2527 #line 860 "rust-exp.y" 2529 #line 2531 "rust-exp.c" 2533 #line 862 "rust-exp.y" 2535 #line 2537 "rust-exp.c" 2539 #line 864 "rust-exp.y" 2541 #line 2543 "rust-exp.c" 2545 #line 866 "rust-exp.y" 2547 #line 2549 "rust-exp.c" 2551 #line 868 "rust-exp.y" 2553 #line 2555 "rust-exp.c" 2557 #line 873 "rust-exp.y" 2558 { (
yyval.params) = NULL; }
2559 #line 2561 "rust-exp.c" 2563 #line 875 "rust-exp.y" 2565 #line 2567 "rust-exp.c" 2569 #line 880 "rust-exp.y" 2572 result->push_back ((
yyvsp[0].op));
2573 (
yyval.params) = result;
2575 #line 2577 "rust-exp.c" 2579 #line 886 "rust-exp.y" 2581 (
yyvsp[-2].params)->push_back ((
yyvsp[0].op));
2584 #line 2586 "rust-exp.c" 2588 #line 2590 "rust-exp.c" 2637 #if ! YYERROR_VERBOSE 2640 # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ 2643 char const *yymsgp =
YY_(
"syntax error");
2644 int yysyntax_error_status;
2645 yysyntax_error_status = YYSYNTAX_ERROR;
2646 if (yysyntax_error_status == 0)
2648 else if (yysyntax_error_status == 1)
2650 if (yymsg != yymsgbuf)
2656 yymsg_alloc =
sizeof yymsgbuf;
2657 yysyntax_error_status = 2;
2661 yysyntax_error_status = YYSYNTAX_ERROR;
2666 if (yysyntax_error_status == 2)
2667 goto yyexhaustedlab;
2669 # undef YYSYNTAX_ERROR 2675 if (yyerrstatus == 3)
2777 #if !defined yyoverflow || YYERROR_VERBOSE 2811 if (yymsg != yymsgbuf)
2816 #line 892 "rust-exp.y" 2832 {
"as",
KW_AS, OP_NULL },
2834 {
"if", 0, OP_NULL },
2835 {
"mut",
KW_MUT, OP_NULL },
2841 {
"fn",
KW_FN, OP_NULL },
2852 {
"<<",
LSH, OP_NULL },
2853 {
">>",
RSH, OP_NULL },
2854 {
"&&",
ANDAND, OP_NULL },
2855 {
"||",
OROR, OP_NULL },
2856 {
"==",
EQEQ, OP_NULL },
2857 {
"!=",
NOTEQ, OP_NULL },
2858 {
"<=",
LTEQ, OP_NULL },
2859 {
">=",
GTEQ, OP_NULL },
2870 {
"..",
DOTDOT, OP_NULL },
2871 {
"->",
ARROW, OP_NULL }
2915 error (
_(
"Could not find crate for current location"));
2917 name->left.sval.ptr, (
char *) NULL));
2934 if (scope[0] ==
'\0')
2935 error (
_(
"Couldn't find namespace scope for self::"));
2940 std::vector<int> offsets;
2941 unsigned int current_len;
2944 while (scope[current_len] !=
'\0')
2946 offsets.push_back (current_len);
2954 len = offsets.size ();
2955 if (n_supers >= len)
2956 error (
_(
"Too many super:: uses from '%s'"), scope);
2958 offset = offsets[len - n_supers];
2969 ident->
right.params);
2986 static struct type *
2995 error (
_(
"Could not find Rust type %s"),
name);
3005 uint32_t result = 0;
3008 int check_max = min == max;
3010 while ((check_max ? len <= max : 1)
3017 result = result + 10 +
lexptr[0] -
'a';
3019 result = result + 10 +
lexptr[0] -
'A';
3021 result = result +
lexptr[0] -
'0';
3027 error (
_(
"Not enough hex digits seen"));
3031 error (
_(
"Overlong hex escape"));
3056 error (
_(
"Unicode escape in byte literal"));
3059 error (
_(
"Missing '{' in Unicode escape"));
3064 error (
_(
"Missing '}' in Unicode escape"));
3098 error (
_(
"Invalid escape \\%c in literal"),
lexptr[0]);
3129 error (
_(
"Unterminated character literal"));
3132 rustyylval.typed_val_int.val =
value;
3133 rustyylval.typed_val_int.
type =
rust_type (is_byte ?
"u8" :
"char");
3144 const char *save = str;
3149 while (str[0] ==
'#')
3165 for (i = 0; i < n; ++i)
3166 if (str[i + 1] !=
'#')
3176 int is_byte =
lexptr[0] ==
'b';
3198 else if (
lexptr[0] ==
'\0')
3199 error (
_(
"Unexpected EOF in string"));
3202 if (is_byte &&
value > 127)
3203 error (
_(
"Non-ASCII value in raw byte string"));
3208 else if (
lexptr[0] ==
'"')
3214 else if (
lexptr[0] ==
'\\')
3225 else if (
lexptr[0] ==
'\0')
3226 error (
_(
"Unexpected EOF in string"));
3230 if (is_byte &&
value > 127)
3231 error (
_(
"Non-ASCII value in byte string"));
3237 rustyylval.sval.length = obstack_object_size (
work_obstack);
3238 rustyylval.sval.ptr = (
const char *) obstack_finish (
work_obstack);
3249 while (p[0] ==
' ' || p[0] ==
'\t')
3254 return *p >=
'0' && *p <=
'9';
3262 return ((c >=
'a' && c <=
'z')
3263 || (c >=
'A' && c <=
'Z')
3273 const char *start =
lexptr;
3277 int is_gdb_var =
lexptr[0] ==
'$';
3288 || (is_gdb_var &&
lexptr[0] ==
'$')
3307 if (
token->value == 0)
3314 else if (
token == NULL
3315 && (strncmp (start,
"thread", length) == 0
3316 || strncmp (start,
"task", length) == 0)
3336 return token->value;
3364 return token->value;
3378 int could_be_decimal = 1;
3379 int implicit_i32 = 0;
3380 const char *type_name = NULL;
3383 int type_index = -1;
3394 end_index = subexps[
INT_TEXT].rm_eo;
3403 could_be_decimal = 0;
3421 end_index = subexps[0].rm_eo;
3430 if (
lexptr[subexps[0].rm_eo - 1] ==
'.')
3438 end_index = subexps[0].rm_eo;
3440 could_be_decimal = 1;
3447 if (type_name == NULL)
3451 (subexps[type_index].rm_eo
3452 - subexps[type_index].rm_so));
3453 type_name = type_name_holder.c_str ();
3461 for (i = 0; i < end_index &&
lexptr[i]; ++i)
3464 could_be_decimal = 0;
3466 number.push_back (
lexptr[i]);
3470 lexptr += subexps[0].rm_eo;
3479 if (number[0] ==
'0')
3481 if (number[1] ==
'x')
3483 else if (number[1] ==
'o')
3485 else if (number[1] ==
'b')
3490 could_be_decimal = 0;
3494 value = strtoul (number.c_str () +
offset, NULL, radix);
3495 if (implicit_i32 &&
value >= ((uint64_t) 1) << 31)
3498 rustyylval.typed_val_int.val =
value;
3499 rustyylval.typed_val_int.
type =
type;
3503 rustyylval.typed_val_float.type =
type;
3504 bool parsed =
parse_float (number.c_str (), number.length (),
3505 rustyylval.typed_val_float.type,
3506 rustyylval.typed_val_float.val);
3551 else if (
lexptr[0] ==
'"')
3553 else if (
lexptr[0] ==
'\'')
3623 result->
opcode = OP_LONG;
3624 result->
left.typed_val_int = val;
3636 result->
opcode = OP_FLOAT;
3637 result->
left.typed_val_float = val;
3657 result->
opcode = UNOP_CAST;
3658 result->
left.op = expr;
3675 result->
left.op = expr;
3676 result->
right.params = params;
3688 result->
opcode = OP_AGGREGATE;
3690 result->
right.field_inits = fields;
3702 result->
opcode = OP_VAR_VALUE;
3703 result->
left.sval = path;
3704 result->
right.params = params;
3716 result->
opcode = OP_STRING;
3717 result->
left.sval = str;
3729 result->
opcode = STRUCTOP_STRUCT;
3745 result->
opcode = STRUCTOP_ANONYMOUS;
3747 result->
right.typed_val_int = number;
3759 result->
opcode = OP_RANGE;
3760 result->
left.op = lhs;
3761 result->
right.op = rhs;
3773 result->
opcode = OP_TYPE;
3785 result->
left.op = lhs;
3786 result->
right.typed_val_int = val;
3832 result->
left.op = rtype;
3833 result->
right.params = params;
3844 result->
left.params = params;
3856 if (strncmp (*
name,
"::", 2) == 0)
3875 if (result.
symbol != NULL)
3882 static struct type *
3891 if (result.
symbol != NULL)
3909 const struct rust_op *operation);
3911 const struct rust_op *operation);
3916 static std::vector<struct type *>
3919 std::vector<struct type *> result;
3921 for (
const rust_op *op : *params)
3929 static struct type *
3931 const struct rust_op *operation)
3935 if (operation->
opcode == OP_VAR_VALUE)
3941 error (
_(
"No typed name '%s' in current context"), varname);
3951 if (operation->
right.typed_val_int.val < 0)
3952 error (
_(
"Negative array length"));
3954 operation->
right.typed_val_int.val - 1);
3975 std::vector<struct type *> args
3977 struct type **argtypes = NULL;
3981 argtypes = args.data ();
3992 std::vector<struct type *> args
3998 for (i = 0; i < args.size (); ++i)
4014 error (
_(
"could not find tuple type '%s'"),
name);
4037 if (operation->
right.params == NULL)
4038 return operation->
left.sval.ptr;
4040 std::vector<struct type *> types
4045 for (i = 0; i < types.size (); ++i)
4060 const struct rust_op *operation,
4062 bool want_type =
false);
4072 for (
const rust_op *elem : *params)
4087 const struct rust_op *operation,
4091 switch (operation->
opcode)
4107 case STRUCTOP_STRUCT:
4119 case STRUCTOP_ANONYMOUS:
4136 case UNOP_COMPLEMENT:
4143 case BINOP_SUBSCRIPT:
4150 case BINOP_BITWISE_AND:
4151 case BINOP_BITWISE_IOR:
4152 case BINOP_BITWISE_XOR:
4155 case BINOP_LOGICAL_OR:
4156 case BINOP_LOGICAL_AND:
4158 case BINOP_NOTEQUAL:
4177 || operation->
opcode == BINOP_ASSIGN)
4207 if (operation->
left.op->opcode == OP_VAR_VALUE)
4222 error (
_(
"Type %s is not a tuple struct"), varname);
4224 for (
int i = 0; i < params->size (); ++i)
4264 const char *varname;
4266 if (operation->
left.sval.ptr[0] ==
'$')
4294 error (
_(
"No symbol '%s' in current context"), varname);
4306 else if (want_type || operation == top)
4313 error (
_(
"Found type '%s', which can't be " 4314 "evaluated in this context"),
4330 if (init.name.ptr != NULL)
4341 if (init.name.ptr == NULL)
4352 error (
_(
"Could not find type '%s'"), operation->
left.sval.ptr);
4357 error (
_(
"Struct expression applied to non-struct type"));
4378 if (operation->
left.op != NULL)
4383 if (operation->
right.op != NULL)
4418 result = rustyyparse ();
4432 error (
_(
"%s in expression, near `%s'."), (msg ? msg :
"Error"), where);
4442 rust_lex_test_init (
const char *input)
4453 rust_lex_test_one (
const char *input,
int expected)
4458 rust_lex_test_init (input);
4462 result = rustyylval;
4476 rust_lex_int_test (
const char *input,
int value,
int kind)
4478 RUSTSTYPE result = rust_lex_test_one (input, kind);
4485 rust_lex_exception_test (
const char *input,
const char *
err)
4504 rust_lex_stringish_test (
const char *input,
const char *
value,
int kind)
4506 RUSTSTYPE result = rust_lex_test_one (input, kind);
4508 SELF_CHECK (strncmp (result.sval.ptr,
value, result.sval.length) == 0);
4514 rust_lex_test_sequence (
const char *input,
int len,
const int expected[])
4521 for (i = 0; i < len; ++i)
4532 rust_lex_test_trailing_dot (
void)
4535 const int expected2[] = {
INTEGER,
'.',
IDENT,
'(',
')', 0 };
4536 const int expected3[] = {
FLOAT,
EQEQ,
'(',
')', 0 };
4539 rust_lex_test_sequence (
"23.g()", ARRAY_SIZE (expected1), expected1);
4540 rust_lex_test_sequence (
"23_0.g()", ARRAY_SIZE (expected2), expected2);
4541 rust_lex_test_sequence (
"23.==()", ARRAY_SIZE (expected3), expected3);
4542 rust_lex_test_sequence (
"23..25", ARRAY_SIZE (expected4), expected4);
4548 rust_lex_test_completion (
void)
4554 rust_lex_test_sequence (
"something.wha", ARRAY_SIZE (expected), expected);
4555 rust_lex_test_sequence (
"something.", ARRAY_SIZE (expected), expected);
4563 rust_lex_test_push_back (
void)
4567 rust_lex_test_init (
">>=");
4585 rust_lex_tests (
void)
4597 rust_lex_test_one (
"", 0);
4598 rust_lex_test_one (
" \t \n \r ", 0);
4599 rust_lex_test_one (
"thread 23", 0);
4600 rust_lex_test_one (
"task 23", 0);
4601 rust_lex_test_one (
"th 104", 0);
4602 rust_lex_test_one (
"ta 97", 0);
4604 rust_lex_int_test (
"'z'",
'z',
INTEGER);
4605 rust_lex_int_test (
"'\\xff'", 0xff,
INTEGER);
4606 rust_lex_int_test (
"'\\u{1016f}'", 0x1016f,
INTEGER);
4607 rust_lex_int_test (
"b'z'",
'z',
INTEGER);
4608 rust_lex_int_test (
"b'\\xfe'", 0xfe,
INTEGER);
4609 rust_lex_int_test (
"b'\\xFE'", 0xfe,
INTEGER);
4610 rust_lex_int_test (
"b'\\xfE'", 0xfe,
INTEGER);
4613 rust_lex_int_test (
"'\\n'",
'\n',
INTEGER);
4614 rust_lex_int_test (
"'\\r'",
'\r',
INTEGER);
4615 rust_lex_int_test (
"'\\t'",
'\t',
INTEGER);
4616 rust_lex_int_test (
"'\\\\'",
'\\',
INTEGER);
4617 rust_lex_int_test (
"'\\0'",
'\0',
INTEGER);
4618 rust_lex_int_test (
"'\\''",
'\'',
INTEGER);
4619 rust_lex_int_test (
"'\\\"'",
'"',
INTEGER);
4621 rust_lex_int_test (
"b'\\n'",
'\n',
INTEGER);
4622 rust_lex_int_test (
"b'\\r'",
'\r',
INTEGER);
4623 rust_lex_int_test (
"b'\\t'",
'\t',
INTEGER);
4624 rust_lex_int_test (
"b'\\\\'",
'\\',
INTEGER);
4625 rust_lex_int_test (
"b'\\0'",
'\0',
INTEGER);
4626 rust_lex_int_test (
"b'\\''",
'\'',
INTEGER);
4627 rust_lex_int_test (
"b'\\\"'",
'"',
INTEGER);
4629 rust_lex_exception_test (
"'z",
"Unterminated character literal");
4630 rust_lex_exception_test (
"b'\\x0'",
"Not enough hex digits seen");
4631 rust_lex_exception_test (
"b'\\u{0}'",
"Unicode escape in byte literal");
4632 rust_lex_exception_test (
"'\\x0'",
"Not enough hex digits seen");
4633 rust_lex_exception_test (
"'\\u0'",
"Missing '{' in Unicode escape");
4634 rust_lex_exception_test (
"'\\u{0",
"Missing '}' in Unicode escape");
4635 rust_lex_exception_test (
"'\\u{0000007}",
"Overlong hex escape");
4636 rust_lex_exception_test (
"'\\u{}",
"Not enough hex digits seen");
4637 rust_lex_exception_test (
"'\\Q'",
"Invalid escape \\Q in literal");
4638 rust_lex_exception_test (
"b'\\Q'",
"Invalid escape \\Q in literal");
4641 rust_lex_int_test (
"2_344__29", 234429,
INTEGER);
4642 rust_lex_int_test (
"0x1f", 0x1f,
INTEGER);
4643 rust_lex_int_test (
"23usize", 23,
INTEGER);
4644 rust_lex_int_test (
"23i32", 23,
INTEGER);
4645 rust_lex_int_test (
"0x1_f", 0x1f,
INTEGER);
4646 rust_lex_int_test (
"0b1_101011__", 0x6b,
INTEGER);
4647 rust_lex_int_test (
"0o001177i64", 639,
INTEGER);
4649 rust_lex_test_trailing_dot ();
4651 rust_lex_test_one (
"23.",
FLOAT);
4652 rust_lex_test_one (
"23.99f32",
FLOAT);
4653 rust_lex_test_one (
"23e7",
FLOAT);
4654 rust_lex_test_one (
"23E-7",
FLOAT);
4655 rust_lex_test_one (
"23e+7",
FLOAT);
4656 rust_lex_test_one (
"23.99e+7f64",
FLOAT);
4657 rust_lex_test_one (
"23.82f32",
FLOAT);
4659 rust_lex_stringish_test (
"hibob",
"hibob",
IDENT);
4660 rust_lex_stringish_test (
"hibob__93",
"hibob__93",
IDENT);
4661 rust_lex_stringish_test (
"thread",
"thread",
IDENT);
4663 rust_lex_stringish_test (
"\"string\"",
"string",
STRING);
4664 rust_lex_stringish_test (
"\"str\\ting\"",
"str\ting",
STRING);
4665 rust_lex_stringish_test (
"\"str\\\"ing\"",
"str\"ing",
STRING);
4666 rust_lex_stringish_test (
"r\"str\\ing\"",
"str\\ing",
STRING);
4667 rust_lex_stringish_test (
"r#\"str\\ting\"#",
"str\\ting",
STRING);
4668 rust_lex_stringish_test (
"r###\"str\\\"ing\"###",
"str\\\"ing",
STRING);
4670 rust_lex_stringish_test (
"b\"string\"",
"string",
BYTESTRING);
4671 rust_lex_stringish_test (
"b\"\x73tring\"",
"string",
BYTESTRING);
4672 rust_lex_stringish_test (
"b\"str\\\"ing\"",
"str\"ing",
BYTESTRING);
4673 rust_lex_stringish_test (
"br####\"\\x73tring\"####",
"\\x73tring",
4682 rust_lex_test_completion ();
4683 rust_lex_test_push_back ();
struct gdbarch * target_gdbarch(void)
mach_port_t mach_port_t name mach_port_t mach_port_t name kern_return_t err
const struct language_defn rust_language_defn
static const struct rust_op * crate_name(const struct rust_op *name)
static const yytype_uint8 yydefact[]
bool rust_tuple_type_p(struct type *type)
struct type * lookup_array_range_type(struct type *element_type, LONGEST low_bound, LONGEST high_bound)
struct parser_state * pstate
static const struct rust_op * ast_struct(const struct rust_op *name, rust_set_vector *fields)
static void yy_symbol_value_print(FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep)
static void munge_name_and_block(const char **name, const struct block **block)
#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
static const struct rust_op * ast_cast(const struct rust_op *expr, const struct rust_op *type)
void write_exp_elt_sym(struct parser_state *ps, struct symbol *expelt)
#define parse_language(ps)
#define parse_gdbarch(ps)
int rust_parse(struct parser_state *state)
bool parse_float(const char *p, int len, const struct type *type, gdb_byte *data)
struct gdbarch * arch() const
static void update_innermost_block(struct block_symbol sym)
void _initialize_rust_exp(void)
static const struct rust_op * ast_structop_anonymous(const struct rust_op *left, struct typed_val_int number)
static const struct rust_op * ast_literal(struct typed_val_int val)
static int lex_operator(void)
static void convert_ast_to_expression(struct parser_state *state, const struct rust_op *operation, const struct rust_op *top, bool want_type=false)
static struct type * rust_type(const char *name)
static uint32_t lex_hex(int min, int max)
static int lex_number(void)
static const char * number_regex_text
#define NUM_SUBEXPRESSIONS
static struct type * rust_lookup_type(const char *name, const struct block *block)
static bool rust_identifier_start_p(char c)
static std::vector< struct type * > convert_params_to_types(struct parser_state *state, rust_op_vector *params)
enum domain_enum_tag domain_enum
static uint32_t lex_escape(int is_byte)
#define SYMBOL_CLASS(symbol)
static auto_obstack * work_obstack
static void convert_params_to_expression(struct parser_state *state, rust_op_vector *params, const struct rust_op *top)
static struct stoken rust_concat3(const char *, const char *, const char *)
static const struct rust_op * ast_dliteral(struct typed_val_float val)
char * get_print_cell(void)
const struct block * innermost_block
std::string rust_crate_for_block(const struct block *block)
static const struct rust_op * ast_slice_type(const struct rust_op *type)
static const struct rust_op * ast_function_type(const struct rust_op *result, rust_op_vector *params)
static const struct rust_op * ast_array_type(const struct rust_op *lhs, struct typed_val_int val)
struct block_symbol lookup_symbol(const char *name, const struct block *block, domain_enum domain, struct field_of_this_result *is_a_field_of_this)
char * skip_spaces(char *chp)
static const struct rust_op * ast_compound_assignment(enum exp_opcode opcode, const struct rust_op *left, const struct rust_op *rust_op)
#define YYPRINT(FILE, TYPE, VALUE)
static struct type * convert_ast_to_type(struct parser_state *state, const struct rust_op *operation)
static struct block_symbol rust_lookup_symbol(const char *name, const struct block *block, const domain_enum domain)
#define yytable_value_is_error(Yytable_value)
static const struct rust_op * ast_pointer_type(const struct rust_op *type, int is_mut)
static const char *const yytname[]
static const yytype_uint16 yyrline[]
scoped_restore_tmpl< T > make_scoped_restore(T *var)
struct type * lookup_typename(const struct language_defn *language, struct gdbarch *gdbarch, const char *name, const struct block *block, int noerr)
void write_exp_elt_block(struct parser_state *ps, const struct block *b)
void write_exp_elt_longcst(struct parser_state *ps, LONGEST expelt)
#define CATCH(EXCEPTION, MASK)
void convert_between_encodings(const char *from, const char *to, const gdb_byte *bytes, unsigned int num_bytes, int width, struct obstack *output, enum transliterations translit)
static const struct rust_op * ast_operation(enum exp_opcode opcode, const struct rust_op *left, const struct rust_op *right)
int contained_in(const struct block *a, const struct block *b)
static const yytype_uint8 yyr1[]
static const yytype_uint8 yystos[]
unsigned int cp_find_first_component(const char *name)
const struct block * block
static rust_parser * current_parser
#define YY_SYMBOL_PRINT(Title, Type, Value, Location)
const struct rust_op * rust_ast
static const yytype_int16 yycheck[]
int symbol_read_needs_frame(struct symbol *sym)
static const char * rust_copy_name(const char *, int)
char * obconcat(struct obstack *obstackp,...)
static const struct rust_op * ast_unary(enum exp_opcode opcode, const struct rust_op *expr)
#define gdb_assert_not_reached(message)
static const struct rust_op * ast_tuple_type(rust_op_vector *params)
static const yytype_int16 yytable[]
static const char * convert_name(struct parser_state *state, const struct rust_op *operation)
static const struct token_info operator_tokens[]
#define YY_STACK_PRINT(Bottom, Top)
const struct language_defn * language() const
bool rust_tuple_struct_type_p(struct type *type)
void rustyyerror(const char *msg)
static const yytype_uint16 yytoknum[]
void write_dollar_variable(struct parser_state *ps, struct stoken str)
struct type * language_bool_type(const struct language_defn *la, struct gdbarch *gdbarch)
void mark_struct_expression(struct parser_state *ps)
static int lex_character(void)
static struct stoken make_stoken(const char *)
#define YYSTACK_RELOCATE(Stack_alloc, Stack)
unsigned short int yytype_uint16
unsigned char yytype_uint8
std::vector< set_field > rust_set_vector
static void yy_symbol_print(FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep)
struct type * rust_slice_type(const char *name, struct type *elt_type, struct type *usize_type)
std::vector< std::unique_ptr< rust_set_vector > > set_vectors
const struct rust_op * init
static const struct token_info identifier_tokens[]
static void rust_push_back(char c)
static const struct rust_op * ast_string(struct stoken str)
static bool space_then_number(const char *string)
void write_exp_elt_opcode(struct parser_state *ps, enum exp_opcode expelt)
rust_op_vector * new_op_vector()
static const char * lexptr
#define YY_REDUCE_PRINT(Rule)
static int starts_raw_string(const char *str)
unsigned char yytype_uint8
#define YYSTACK_ALLOC_MAXIMUM
#define yypact_value_is_default(Yystate)
static const struct rust_op * ast_reference_type(const struct rust_op *type)
static void yy_reduce_print(yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule)
int xsnprintf(char *str, size_t size, const char *format,...)
static const struct rust_op * super_name(const struct rust_op *name, unsigned int n_supers)
#define TYPE_CODE(thistype)
const struct block * block_static_block(const struct block *block)
static const yytype_uint8 yytranslate[]
static struct rust_op * ast_basic_type(enum type_code typecode)
#define TYPE_NFIELDS(thistype)
#define obstack_grow_str(OBSTACK, STRING)
static const yytype_int16 yypact[]
static regex_t number_regex
const struct block * expression_context_block
rust_parser(struct parser_state *state)
rust_set_vector * field_inits
static void yydestruct(const char *yymsg, int yytype, YYSTYPE *yyvaluep)
#define obstack_grow_str0(OBSTACK, STRING)
struct type * lookup_function_type_with_arguments(struct type *type, int nparams, struct type **param_types)
#define YY_IGNORE_MAYBE_UNINITIALIZED_END
#define SYMBOL_TYPE(symbol)
const struct rust_op * op
static const yytype_int16 yypgoto[]
static int lex_string(void)
#define OBSTACK_ZALLOC(OBSTACK, TYPE)
struct type * language_lookup_primitive_type(const struct language_defn *la, struct gdbarch *gdbarch, const char *name)
struct set_field one_field_init
std::string type_to_string(struct type *type)
static const yytype_uint8 yyr2[]
static const struct rust_op * ast_structop(const struct rust_op *left, const char *name, int completing)
static const struct rust_op * ast_range(const struct rust_op *lhs, const struct rust_op *rhs)
unsigned int compound_assignment
rust_set_vector * new_set_vector()
static const char * prev_lexptr
void write_exp_elt_floatcst(struct parser_state *ps, const gdb_byte expelt[16])
void write_exp_string(struct parser_state *ps, struct stoken str)
static void yy_stack_print(yytype_int16 *yybottom, yytype_int16 *yytop)
void write_exp_elt_type(struct parser_state *ps, struct type *expelt)
static int lex_identifier(void)
void register_test(const std::string &name, selftest *test)
unsigned short int yytype_uint16
void error(const char *fmt,...)
const char * block_scope(const struct block *block)
static const struct rust_op * ast_path(struct stoken name, rust_op_vector *params)
static const yytype_int16 yydefgoto[]
struct type * lookup_pointer_type(struct type *type)
std::vector< std::unique_ptr< rust_op_vector > > op_vectors
static const struct rust_op * ast_call_ish(enum exp_opcode opcode, const struct rust_op *expr, rust_op_vector *params)
static int rustyylex(void)
#define SELF_CHECK(VALUE)
static bool ends_raw_string(const char *str, int n)
std::vector< const struct rust_op * > rust_op_vector