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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e289b5ceae0f39c3,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-07-21 12:54:21 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!newspump.monmouth.com!newspeer.monmouth.com!newsfeed.icl.net!newsfeed.fjserv.net!diablo.theplanet.net!newspeer1-gui.server.ntli.net!ntli.net!newsfep4-glfd.server.ntli.net.POSTED!53ab2750!not-for-mail From: chris User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Binding to C Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Mon, 21 Jul 2003 20:59:30 +0200 NNTP-Posting-Host: 81.98.236.164 X-Complaints-To: abuse@ntlworld.com X-Trace: newsfep4-glfd.server.ntli.net 1058817260 81.98.236.164 (Mon, 21 Jul 2003 20:54:20 BST) NNTP-Posting-Date: Mon, 21 Jul 2003 20:54:20 BST Organization: ntl Cablemodem News Service Xref: archiver1.google.com comp.lang.ada:40579 Date: 2003-07-21T20:59:30+02:00 List-Id: Hi, I came across the following in libjpeg... what should I map it to? const char* const* jpeg_message_table Also does anyone have any advice in general mapping to C. For the jpeg_error_mgr struct, I mapped ptrs to functions to System.Address and made the struct a record. Will this work, or will the corresponding type of the struct have to be a System.Address? Chris package Low_Jpg.Error is package C renames Interfaces.C; type Jpeg_Error_Mgr is record Error_Exit : System.Address; -- addr of a handler Emit_Message : System.Address; Output_Message : System.Address; Format_Message : System.Address; Reset_Error_Mgr : System.Address; Msg_Code : C.Int; Msg_Parm : System.Address; Trace_Level : C.Int; Num_Warnings : C.Long; end record; pragma Convention (C, Jpeg_Error_Mgr); end Low_Jpg.Error;