From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Thread: 103376,ac6f6c30c45f808a X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!oleane.net!oleane!freenix!enst.fr!melchior!cuivre.fr.eu.org!melchior.frmug.org!not-for-mail From: Stephen Leake Newsgroups: comp.lang.ada Subject: Re: Ada equivalent for C-pointer? Date: 14 Jan 2005 18:03:32 -0500 Organization: Cuivre, Argent, Or Message-ID: References: <41E7F653.2F899F47@alfred-hilscher.de> NNTP-Posting-Host: lovelace.ada-france.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: melchior.cuivre.fr.eu.org 1105743826 50289 212.85.156.195 (14 Jan 2005 23:03:46 GMT) X-Complaints-To: usenet@melchior.cuivre.fr.eu.org NNTP-Posting-Date: Fri, 14 Jan 2005 23:03:46 +0000 (UTC) To: comp.lang.ada@ada-france.org Return-Path: In-Reply-To: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at ada-france.org X-BeenThere: comp.lang.ada@ada-france.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Gateway to the comp.lang.ada Usenet newsgroup" List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Xref: g2news1.google.com comp.lang.ada:7786 Date: 2005-01-14T18:03:32-05:00 Keith Thompson writes: > Alfred Hilscher writes: > > I want to interface to a C-function expecting a "far *", what have I to > > pass: an "access all ..." or "System.Address"? Are there differences > > between access and address, or are their internal representations equal? > > I use GNAT 3.15p. > > "far" pointers are an old Microsoft kludge. The C standard doesn't > define "far" pointers, and an Ada compiler's interface to C likely > doesn't either. To be somewhat more helpful: On older x86 systems, when 16 bit operating systems were used, there were two kinds of pointers; "near" pointers, 16 bits in size, and "far" pointers, 32 or 48 bits in size. These days, you should interpret "far" as a noop, and just think of it as a pointer. Whether it is 16, 32, or 64 bits depends on what machine, OS, and compiler you are using. -- -- Stephe