diff -Nrc3pad gcc-3.3.2/gcc/objc/objc-act.c gcc-3.3.3/gcc/objc/objc-act.c *** gcc-3.3.2/gcc/objc/objc-act.c Thu Oct 24 00:46:02 2002 --- gcc-3.3.3/gcc/objc/objc-act.c Sat Jan 24 14:21:15 2004 *************** is_private (decl) *** 5848,5858 **** { if (TREE_PRIVATE (decl) && ! is_ivar (CLASS_IVARS (implementation_template), DECL_NAME (decl))) ! { ! error ("instance variable `%s' is declared private", ! IDENTIFIER_POINTER (DECL_NAME (decl))); ! return 1; ! } else return 0; } --- 5848,5854 ---- { if (TREE_PRIVATE (decl) && ! is_ivar (CLASS_IVARS (implementation_template), DECL_NAME (decl))) ! return 1; else return 0; } *************** is_public (expr, identifier) *** 5894,5900 **** == CATEGORY_IMPLEMENTATION_TYPE)) && (CLASS_NAME (objc_implementation_context) == TYPE_NAME (basetype)))) ! return ! is_private (decl); error ("instance variable `%s' is declared %s", IDENTIFIER_POINTER (identifier), --- 5890,5903 ---- == CATEGORY_IMPLEMENTATION_TYPE)) && (CLASS_NAME (objc_implementation_context) == TYPE_NAME (basetype)))) ! { ! int private = is_private (decl); ! if (private) ! error ("instance variable '%s' is declared private", ! IDENTIFIER_POINTER (DECL_NAME (decl))); ! ! return !private; ! } error ("instance variable `%s' is declared %s", IDENTIFIER_POINTER (identifier), *************** lookup_objc_ivar (id) *** 8524,8530 **** else if (objc_method_context && (decl = is_ivar (objc_ivar_chain, id))) { if (is_private (decl)) ! return error_mark_node; else return build_ivar_reference (id); } --- 8527,8533 ---- else if (objc_method_context && (decl = is_ivar (objc_ivar_chain, id))) { if (is_private (decl)) ! return 0; else return build_ivar_reference (id); } diff -Nrc3pad gcc-3.3.2/gcc/objc/objc-parse.c gcc-3.3.3/gcc/objc/objc-parse.c *** gcc-3.3.2/gcc/objc/objc-parse.c Thu Oct 16 20:53:44 2003 --- gcc-3.3.3/gcc/objc/objc-parse.c Sat Feb 14 20:46:56 2004 *************** *** 1,5 **** /* A Bison parser, made from objc-parse.y ! by GNU bison 1.35. */ #define YYBISON 1 /* Identify Bison output. */ --- 1,5 ---- /* A Bison parser, made from objc-parse.y ! by GNU bison 1.33. */ #define YYBISON 1 /* Identify Bison output. */ *************** do { \ *** 144,150 **** typedef union {long itype; tree ttype; enum tree_code code; const char *filename; int lineno; } yystype; # define YYSTYPE yystype - # define YYSTYPE_IS_TRIVIAL 1 #endif #line 248 "objc-parse.y" --- 144,149 ---- *************** static const short yycheck[] = *** 2267,2272 **** --- 2266,2281 ---- define necessary library symbols; they are noted "INFRINGES ON USER NAME SPACE" below. */ + #ifdef __cplusplus + # define YYSTD(x) std::x + #else + # define YYSTD(x) x + #endif + + #ifndef YYPARSE_RETURN_TYPE + #define YYPARSE_RETURN_TYPE int + #endif + #if ! defined (yyoverflow) || defined (YYERROR_VERBOSE) /* The parser invokes alloca or malloc; define the necessary symbols. */ *************** static const short yycheck[] = *** 2289,2307 **** /* Pacify GCC's `empty if-body' warning. */ # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) # else ! # if defined (__STDC__) || defined (__cplusplus) ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T size_t # endif ! # define YYSTACK_ALLOC malloc ! # define YYSTACK_FREE free # endif - #endif /* ! defined (yyoverflow) || defined (YYERROR_VERBOSE) */ - - - #if (! defined (yyoverflow) \ - && (! defined (__cplusplus) \ - || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) /* A type that is properly aligned for any stack member. */ union yyalloc --- 2298,2315 ---- /* Pacify GCC's `empty if-body' warning. */ # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) # else ! # ifdef __cplusplus ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T std::size_t ! # else ! # ifdef __STDC__ ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T size_t ! # endif # endif ! # define YYSTACK_ALLOC YYSTD (malloc) ! # define YYSTACK_FREE YYSTD (free) # endif /* A type that is properly aligned for any stack member. */ union yyalloc *************** union yyalloc *** 2328,2368 **** + YYSTACK_GAP_MAX) # endif ! /* Copy COUNT objects from FROM to TO. The source and destination do ! not overlap. */ ! # ifndef YYCOPY ! # if 1 < __GNUC__ ! # define YYCOPY(To, From, Count) \ ! __builtin_memcpy (To, From, (Count) * sizeof (*(From))) ! # else ! # define YYCOPY(To, From, Count) \ ! do \ ! { \ ! register YYSIZE_T yyi; \ ! for (yyi = 0; yyi < (Count); yyi++) \ ! (To)[yyi] = (From)[yyi]; \ ! } \ ! while (0) ! # endif ! # endif ! ! /* Relocate STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of elements in the stack, and YYPTR gives the new location of the stack. Advance YYPTR to a properly aligned location for the next stack. */ ! # define YYSTACK_RELOCATE(Stack) \ do \ { \ YYSIZE_T yynewbytes; \ ! YYCOPY (&yyptr->Stack, Stack, yysize); \ Stack = &yyptr->Stack; \ ! yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX; \ yyptr += yynewbytes / sizeof (*yyptr); \ } \ while (0) ! #endif #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) --- 2336,2359 ---- + YYSTACK_GAP_MAX) # endif ! /* Relocate the TYPE STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of elements in the stack, and YYPTR gives the new location of the stack. Advance YYPTR to a properly aligned location for the next stack. */ ! # define YYSTACK_RELOCATE(Type, Stack) \ do \ { \ YYSIZE_T yynewbytes; \ ! yymemcpy ((char *) yyptr, (char *) (Stack), \ ! yysize * (YYSIZE_T) sizeof (Type)); \ Stack = &yyptr->Stack; \ ! yynewbytes = yystacksize * sizeof (Type) + YYSTACK_GAP_MAX; \ yyptr += yynewbytes / sizeof (*yyptr); \ } \ while (0) ! #endif /* ! defined (yyoverflow) || defined (YYERROR_VERBOSE) */ #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) *************** union yyalloc *** 2372,2380 **** # define YYSIZE_T size_t #endif #if ! defined (YYSIZE_T) ! # if defined (__STDC__) || defined (__cplusplus) ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T size_t # endif #endif #if ! defined (YYSIZE_T) --- 2363,2376 ---- # define YYSIZE_T size_t #endif #if ! defined (YYSIZE_T) ! # ifdef __cplusplus ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T std::size_t ! # else ! # ifdef __STDC__ ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYSIZE_T size_t ! # endif # endif #endif #if ! defined (YYSIZE_T) *************** while (0) *** 2453,2460 **** #if YYDEBUG # ifndef YYFPRINTF ! # include /* INFRINGES ON USER NAME SPACE */ ! # define YYFPRINTF fprintf # endif # define YYDPRINTF(Args) \ --- 2449,2460 ---- #if YYDEBUG # ifndef YYFPRINTF ! # ifdef __cplusplus ! # include /* INFRINGES ON USER NAME SPACE */ ! # else ! # include /* INFRINGES ON USER NAME SPACE */ ! # endif ! # define YYFPRINTF YYSTD (fprintf) # endif # define YYDPRINTF(Args) \ *************** do { \ *** 2462,2469 **** if (yydebug) \ YYFPRINTF Args; \ } while (0) ! /* Nonzero means print parse trace. It is left uninitialized so that ! multiple parsers can coexist. */ int yydebug; #else /* !YYDEBUG */ # define YYDPRINTF(Args) --- 2462,2471 ---- if (yydebug) \ YYFPRINTF Args; \ } while (0) ! /* Nonzero means print parse trace. [The following comment makes no ! sense to me. Could someone clarify it? --akim] Since this is ! uninitialized, it does not stop multiple parsers from coexisting. ! */ int yydebug; #else /* !YYDEBUG */ # define YYDPRINTF(Args) *************** int yydebug; *** 2489,2494 **** --- 2491,2523 ---- # define YYMAXDEPTH 10000 #endif + #if ! defined (yyoverflow) && ! defined (yymemcpy) + # if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ + # define yymemcpy __builtin_memcpy + # else /* not GNU C or C++ */ + + /* This is the most reliable way to avoid incompatibilities + in available built-in functions on various systems. */ + static void + # if defined (__STDC__) || defined (__cplusplus) + yymemcpy (char *yyto, const char *yyfrom, YYSIZE_T yycount) + # else + yymemcpy (yyto, yyfrom, yycount) + char *yyto; + const char *yyfrom; + YYSIZE_T yycount; + # endif + { + register const char *yyf = yyfrom; + register char *yyt = yyto; + register YYSIZE_T yyi = yycount; + + while (yyi-- != 0) + *yyt++ = *yyf++; + } + # endif + #endif + #ifdef YYERROR_VERBOSE # ifndef yystrlen *************** yystpcpy (yydest, yysrc) *** 2541,2547 **** # endif #endif ! #line 315 "/usr/share/bison/bison.simple" /* The user can define YYPARSE_PARAM as the name of an argument to be passed --- 2570,2576 ---- # endif #endif ! #line 345 "/usr/share/bison/bison.simple" /* The user can define YYPARSE_PARAM as the name of an argument to be passed *************** yystpcpy (yydest, yysrc) *** 2551,2563 **** to the proper pointer type. */ #ifdef YYPARSE_PARAM ! # if defined (__STDC__) || defined (__cplusplus) # define YYPARSE_PARAM_ARG void *YYPARSE_PARAM # define YYPARSE_PARAM_DECL ! # else # define YYPARSE_PARAM_ARG YYPARSE_PARAM # define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; ! # endif #else /* !YYPARSE_PARAM */ # define YYPARSE_PARAM_ARG # define YYPARSE_PARAM_DECL --- 2580,2592 ---- to the proper pointer type. */ #ifdef YYPARSE_PARAM ! # ifdef __cplusplus # define YYPARSE_PARAM_ARG void *YYPARSE_PARAM # define YYPARSE_PARAM_DECL ! # else /* !__cplusplus */ # define YYPARSE_PARAM_ARG YYPARSE_PARAM # define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; ! # endif /* !__cplusplus */ #else /* !YYPARSE_PARAM */ # define YYPARSE_PARAM_ARG # define YYPARSE_PARAM_DECL *************** yystpcpy (yydest, yysrc) *** 2566,2574 **** /* Prevent warning if -Wstrict-prototypes. */ #ifdef __GNUC__ # ifdef YYPARSE_PARAM ! int yyparse (void *); # else ! int yyparse (void); # endif #endif --- 2595,2603 ---- /* Prevent warning if -Wstrict-prototypes. */ #ifdef __GNUC__ # ifdef YYPARSE_PARAM ! YYPARSE_RETURN_TYPE yyparse (void *); # else ! YYPARSE_RETURN_TYPE yyparse (void); # endif #endif *************** YY_DECL_NON_LSP_VARIABLES *** 2603,2609 **** YY_DECL_VARIABLES #endif /* !YYPURE */ ! int yyparse (YYPARSE_PARAM_ARG) YYPARSE_PARAM_DECL { --- 2632,2638 ---- YY_DECL_VARIABLES #endif /* !YYPURE */ ! YYPARSE_RETURN_TYPE yyparse (YYPARSE_PARAM_ARG) YYPARSE_PARAM_DECL { *************** yyparse (YYPARSE_PARAM_ARG) *** 2731,2739 **** yyvs = yyvs1; } #else /* no yyoverflow */ - # ifndef YYSTACK_RELOCATE - goto yyoverflowlab; - # else /* Extend the stack our own way. */ if (yystacksize >= YYMAXDEPTH) goto yyoverflowlab; --- 2760,2765 ---- *************** yyparse (YYPARSE_PARAM_ARG) *** 2747,2762 **** (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); if (! yyptr) goto yyoverflowlab; ! YYSTACK_RELOCATE (yyss); ! YYSTACK_RELOCATE (yyvs); # if YYLSP_NEEDED ! YYSTACK_RELOCATE (yyls); # endif # undef YYSTACK_RELOCATE if (yyss1 != yyssa) YYSTACK_FREE (yyss1); } - # endif #endif /* no yyoverflow */ yyssp = yyss + yysize - 1; --- 2773,2787 ---- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); if (! yyptr) goto yyoverflowlab; ! YYSTACK_RELOCATE (short, yyss); ! YYSTACK_RELOCATE (YYSTYPE, yyvs); # if YYLSP_NEEDED ! YYSTACK_RELOCATE (YYLTYPE, yyls); # endif # undef YYSTACK_RELOCATE if (yyss1 != yyssa) YYSTACK_FREE (yyss1); } #endif /* no yyoverflow */ yyssp = yyss + yysize - 1; *************** case 720: *** 5746,5752 **** break;} } ! #line 705 "/usr/share/bison/bison.simple" yyvsp -= yylen; --- 5771,5777 ---- break;} } ! #line 731 "/usr/share/bison/bison.simple" yyvsp -= yylen; diff -Nrc3pad gcc-3.3.2/libobjc/ChangeLog gcc-3.3.3/libobjc/ChangeLog *** gcc-3.3.2/libobjc/ChangeLog Thu Oct 16 19:45:19 2003 --- gcc-3.3.3/libobjc/ChangeLog Sat Feb 14 20:20:25 2004 *************** *** 1,3 **** --- 1,14 ---- + 2004-02-14 Release Manager + + * GCC 3.3.3 Released. + + 2003-12-01 Zack Weinberg + + PR 11433 + * Protocol.m (descriptionForInstanceMethod): Don't dereference + instance_methods if it's NULL. + (descriptionForClassMethod): Likewise for class_methods. + 2003-10-16 Release Manager * GCC 3.3.2 Released. *************** Mon Dec 17 17:02:12 2001 Nicola Pero < *** 188,194 **** 2001-11-14 Aldy Hernandez ! * encoding.c: Add target_flags. 2001-11-07 Aldy Hernandez --- 199,205 ---- 2001-11-14 Aldy Hernandez ! * encoding.c: Add target_flags. 2001-11-07 Aldy Hernandez *************** Mon Dec 17 17:02:12 2001 Nicola Pero < *** 199,216 **** Mon Oct 29 21:29:21 2001 Nicola Pero * class.c: Rewritten the class table to use optimized, lock-free ! lookup. This more than doubles the speed of class method ! invocations. (class_table_setup), (class_table_insert), ! (class_table_replace), (class_table_get_safe), ! (class_table_next), (class_table_print), ! (class_table_print_histogram): New functions. ! (__objc_init_class_tables): Use class_table_setup. ! (__objc_add_class_to_hash): Use class_table_get_safe and ! class_table_insert. (objc_lookup_class), (objc_get_class): Do not ! assert the existence of the table; do not lock the runtime; use ! class_table_get_safe. (objc_next_class): Use class_table_next. ! (__objc_resolve_class_links): Use class_table_next. ! (class_pose_as): Use class_table_replace. 2001-09-10 Ovidiu Predescu --- 210,227 ---- Mon Oct 29 21:29:21 2001 Nicola Pero * class.c: Rewritten the class table to use optimized, lock-free ! lookup. This more than doubles the speed of class method ! invocations. (class_table_setup), (class_table_insert), ! (class_table_replace), (class_table_get_safe), ! (class_table_next), (class_table_print), ! (class_table_print_histogram): New functions. ! (__objc_init_class_tables): Use class_table_setup. ! (__objc_add_class_to_hash): Use class_table_get_safe and ! class_table_insert. (objc_lookup_class), (objc_get_class): Do not ! assert the existence of the table; do not lock the runtime; use ! class_table_get_safe. (objc_next_class): Use class_table_next. ! (__objc_resolve_class_links): Use class_table_next. ! (class_pose_as): Use class_table_replace. 2001-09-10 Ovidiu Predescu diff -Nrc3pad gcc-3.3.2/libobjc/Protocol.m gcc-3.3.3/libobjc/Protocol.m *** gcc-3.3.2/libobjc/Protocol.m Sat Jun 15 17:50:13 2002 --- gcc-3.3.3/libobjc/Protocol.m Tue Dec 2 01:59:37 2003 *************** struct objc_method_description_list { *** 80,90 **** const char* name = sel_get_name (aSel); struct objc_method_description *result; ! for (i = 0; i < instance_methods->count; i++) ! { ! if (!strcmp ((char*)instance_methods->list[i].name, name)) ! return &(instance_methods->list[i]); ! } for (proto_list = protocol_list; proto_list; proto_list = proto_list->next) { --- 80,91 ---- const char* name = sel_get_name (aSel); struct objc_method_description *result; ! if (instance_methods) ! for (i = 0; i < instance_methods->count; i++) ! { ! if (!strcmp ((char*)instance_methods->list[i].name, name)) ! return &(instance_methods->list[i]); ! } for (proto_list = protocol_list; proto_list; proto_list = proto_list->next) { *************** struct objc_method_description_list { *** 107,117 **** const char* name = sel_get_name (aSel); struct objc_method_description *result; ! for (i = 0; i < class_methods->count; i++) ! { ! if (!strcmp ((char*)class_methods->list[i].name, name)) ! return &(class_methods->list[i]); ! } for (proto_list = protocol_list; proto_list; proto_list = proto_list->next) { --- 108,119 ---- const char* name = sel_get_name (aSel); struct objc_method_description *result; ! if (class_methods) ! for (i = 0; i < class_methods->count; i++) ! { ! if (!strcmp ((char*)class_methods->list[i].name, name)) ! return &(class_methods->list[i]); ! } for (proto_list = protocol_list; proto_list; proto_list = proto_list->next) {