From patchwork Sun Dec 19 00:29:25 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicola Pero X-Patchwork-Id: 76105 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 885D3B70CC for ; Sun, 19 Dec 2010 11:29:45 +1100 (EST) Received: (qmail 22504 invoked by alias); 19 Dec 2010 00:29:39 -0000 Received: (qmail 22490 invoked by uid 22791); 19 Dec 2010 00:29:36 -0000 X-SWARE-Spam-Status: No, hits=-1.3 required=5.0 tests=AWL, BAYES_00, SARE_SUB_ENC_UTF8, TW_BJ, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from fencepost.gnu.org (HELO fencepost.gnu.org) (140.186.70.10) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 19 Dec 2010 00:29:31 +0000 Received: from eggs.gnu.org ([140.186.70.92]:46575) by fencepost.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1PU79S-0005cU-Nf for gcc-patches@gnu.org; Sat, 18 Dec 2010 19:29:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PU79U-0007VS-Av for gcc-patches@gnu.org; Sat, 18 Dec 2010 19:29:29 -0500 Received: from smtp191.iad.emailsrvr.com ([207.97.245.191]:42524) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PU79U-0007VO-8j for gcc-patches@gnu.org; Sat, 18 Dec 2010 19:29:28 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp39.relay.iad1a.emailsrvr.com (SMTP Server) with ESMTP id A1F5C98459 for ; Sat, 18 Dec 2010 19:29:25 -0500 (EST) Received: from dynamic4.wm-web.iad.mlsrvr.com (dynamic4.wm-web.iad1a.rsapps.net [192.168.2.153]) by smtp39.relay.iad1a.emailsrvr.com (SMTP Server) with ESMTP id 913839844F for ; Sat, 18 Dec 2010 19:29:25 -0500 (EST) Received: from meta-innovation.com (localhost [127.0.0.1]) by dynamic4.wm-web.iad.mlsrvr.com (Postfix) with ESMTP id 5B7D61D4A2AE for ; Sat, 18 Dec 2010 19:29:25 -0500 (EST) Received: by www2.webmail.us (Authenticated sender: nicola.pero@meta-innovation.com, from: nicola.pero@meta-innovation.com) with HTTP; Sun, 19 Dec 2010 01:29:25 +0100 (CET) Date: Sun, 19 Dec 2010 01:29:25 +0100 (CET) Subject: =?UTF-8?Q?libobjc:=20header=20cleanup=20for=20the=20new=20API=20(1)?= From: "Nicola Pero" To: "gcc-patches@gnu.org" MIME-Version: 1.0 X-Type: plain Message-ID: <1292718565.373214880@192.168.2.229> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org I'm reviewing the libobjc headers - checking that functions, types, etc. in the new and old APIs are defined in the right header, tidying up comments and fixing other minor details left lose when the new API was added. Please bear with me with the following sequence of patches - each of them is basically a very small bufix/tidyup of the libobjc headers. I should be finished in a couple of days. This first patch just removes a TODO and moves a private declaration in the right header file. Committed to trunk. Thanks Index: init.c =================================================================== --- init.c (revision 168034) +++ init.c (working copy) @@ -32,6 +32,7 @@ #include "objc-private/objc-list.h" #include "objc-private/module-abi-8.h" #include "objc-private/runtime.h" +#include "objc-private/selector.h" /* For __sel_register_typed_name(). */ #include "objc-private/objc-sync.h" /* For __objc_sync_init() */ #include "objc-private/protocols.h" /* For __objc_protocols_init(), __objc_protocols_add_protocol() @@ -92,11 +93,6 @@ /* Are all categories/classes resolved? */ BOOL __objc_dangling_categories = NO; /* !T:UNUSED */ -/* TODO: This needs to go into objc-private/selector.h. */ -extern SEL -__sel_register_typed_name (const char *name, const char *types, - struct objc_selector *orig, BOOL is_const); - /* Sends +load to all classes and categories in certain situations. */ static void objc_send_load (void); Index: objc-private/selector.h =================================================================== --- objc-private/selector.h (revision 168034) +++ objc-private/selector.h (working copy) @@ -45,6 +45,10 @@ SEL sel_get_any_uid (const char *name); +SEL +__sel_register_typed_name (const char *name, const char *types, + struct objc_selector *orig, BOOL is_const); + #ifdef __cplusplus } #endif /* __cplusplus */ Index: selector.c =================================================================== --- selector.c (revision 168034) +++ selector.c (working copy) @@ -30,6 +30,7 @@ #include "objc-private/module-abi-8.h" #include "objc-private/runtime.h" #include "objc-private/sarray.h" +#include "objc-private/selector.h" /* Initial selector hash table size. Value doesn't matter much. */ #define SELECTOR_HASH_SIZE 128 Index: ChangeLog =================================================================== --- ChangeLog (revision 168034) +++ ChangeLog (working copy) @@ -1,3 +1,10 @@ +2010-12-19 Nicola Pero + + * init.c: Include objc-private/selector.h. Do not declare + __sel_register_typed_name. + * objc-private/selector.h (__sel_register_typed_name): Declare. + * selector.c: Include objc-private/selector.h. + 2010-12-18 Nicola Pero * class.c: Tidied up comments and indentation. No code changes.