From patchwork Tue Aug 8 17:51:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Eggert X-Patchwork-Id: 799376 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-82880-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="c67ZqC4V"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3xRhmr644lz9s7C for ; Wed, 9 Aug 2017 03:52:12 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:cc:references:from:message-id:date :mime-version:in-reply-to:content-type; q=dns; s=default; b=Lxy8 FhyIXY2gMtF8i3k+q0B8oAOXi8PFp3S8EEsMJ+1V5QLUMrNnBPj+/ZheMl2gl2G/ r3PbE+IMdBUGEUe2eaonXF9Zkx0Ji/X2yCNwNt5Lj0Ij7veNacN4gUBqp2uhXh+V 6ExBqq0IHmrKcNCohsXBh2b3jDCEvzYW6wZkaak= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:cc:references:from:message-id:date :mime-version:in-reply-to:content-type; s=default; bh=KyqwjKXGH8 Q/Z6K19lQy1v22txI=; b=c67ZqC4VLe0GJYuu4PudeV/H7ffRtK5Hc3scE/UfZN 0Kt+Syp0amBwPKoU5YFm9YQ+ronnOv2hpPC4OiLHSo2o9ETVKX6WAAVmh8pkxpcP Da5Hw5QD8sNCKyrf8jTgfMY7j5yzQwhM3l9qPRcglXbYy+mxULxiT2t21fmGQwci 8= Received: (qmail 97949 invoked by alias); 8 Aug 2017 17:52:04 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 97930 invoked by uid 89); 8 Aug 2017 17:52:03 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.1 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_LOW, RP_MATCHES_RCVD, SPF_PASS, URIBL_RED autolearn=ham version=3.3.2 spammy= X-HELO: zimbra.cs.ucla.edu Subject: Re: Do not use __ptr_t To: Joseph Myers Cc: Zack Weinberg , GNU C Library References: <2d47fc00-e581-fa36-381c-a5b82d980b6d@cs.ucla.edu> From: Paul Eggert Message-ID: Date: Tue, 8 Aug 2017 10:51:58 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: Joseph Myers wrote: > Would you like to propose a patch (that deprecates __ptr_t like that Sure, that's easy enough. Proposed patch attached. From b9c1e6917d284b578bcce7b3dc42b4e258b004c2 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 8 Aug 2017 10:50:16 -0700 Subject: [PATCH] Deprecate __ptr_t * NEWS: Mention this. * misc/sys/cdefs.h (__ptr_t): Mark it as deprecated. --- ChangeLog | 6 ++++++ NEWS | 2 +- misc/sys/cdefs.h | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 12d0a7d23e..76716e2d91 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2017-08-08 Paul Eggert + + Deprecate __ptr_t + * NEWS: Mention this. + * misc/sys/cdefs.h (__ptr_t): Mark it as deprecated. + 2017-08-08 Joseph Myers * malloc/mcheck.c (old_free_hook): Use void * instead of __ptr_t. diff --git a/NEWS b/NEWS index 4b7e69a1db..68520e9a46 100644 --- a/NEWS +++ b/NEWS @@ -13,7 +13,7 @@ Major new features: Deprecated and removed features, and other changes affecting compatibility: - [Add deprecations, removals and changes affecting compatibility here] +* The __ptr_t macro is deprecated. Programs should use 'void *' instead. Changes to build and runtime requirements: diff --git a/misc/sys/cdefs.h b/misc/sys/cdefs.h index b3e7f3be96..034e75267d 100644 --- a/misc/sys/cdefs.h +++ b/misc/sys/cdefs.h @@ -101,7 +101,7 @@ #define __STRING(x) #x /* This is not a typedef so `const __ptr_t' does the right thing. */ -#define __ptr_t void * +#define __ptr_t void * __glibc_macro_warning ("__ptr_t is deprecated") /* C++ needs to know that types and declarations are C, not C++. */ -- 2.13.3