From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21524 invoked by alias); 16 Jul 2012 14:42:48 -0000 Received: (qmail 21514 invoked by uid 22791); 16 Jul 2012 14:42:47 -0000 X-SWARE-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from mel.act-europe.fr (HELO mel.act-europe.fr) (194.98.77.210) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 16 Jul 2012 14:42:35 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id 447F829002C; Mon, 16 Jul 2012 16:42:40 +0200 (CEST) Received: from mel.act-europe.fr ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id y8EPL1H1JTyD; Mon, 16 Jul 2012 16:42:40 +0200 (CEST) Received: from ulanbator.act-europe.fr (ulanbator.act-europe.fr [10.10.1.67]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mel.act-europe.fr (Postfix) with ESMTP id 13D09290012; Mon, 16 Jul 2012 16:42:39 +0200 (CEST) Subject: Re: [Ada] Ease interface with builtins that returns void * Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: text/plain; charset=iso-8859-1 From: Tristan Gingold In-Reply-To: <500426ED.4090508@free.fr> Date: Mon, 16 Jul 2012 14:42:00 -0000 Cc: gcc-patches@gcc.gnu.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <20120716131054.GA5416@adacore.com> <50041411.1050302@free.fr> <50041604.20702@free.fr> <5BFC03FE-26B2-4932-8BAD-29380D188370@adacore.com> <50041E04.8070009@free.fr> <500426ED.4090508@free.fr> To: Duncan Sands X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2012-07/txt/msg00661.txt.bz2 On Jul 16, 2012, at 4:36 PM, Duncan Sands wrote: > Hi Tristan, >=20 >> Ah, what you want is the use of 'void *' for System.Address. >> We didn't choose that because the semantic of System.Address (which incl= udes arithmetic on the whole address space) doesn't match the void * one. >=20 > void* arithmetic of this kind exists, it's a gcc extension to C :) The issue is not void * vs char *, but the fact that the C standard has res= triction on pointer arithmetic. >> But, you can try to implement this scheme by modifying the runtime. I d= on't know if this is a small work or not. >=20 > It crashes the front-end, so it's not trivial. :-)