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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,dafbabe75fb94e5f X-Google-Attributes: gid103376,public From: dewar@cs.nyu.edu (Robert Dewar) Subject: Re: C++ to Ada 95 "thin" binding generator? Date: 1996/02/21 Message-ID: #1/1 X-Deja-AN: 140554988 references: organization: Courant Institute of Mathematical Sciences newsgroups: comp.lang.ada Date: 1996-02-21T00:00:00+00:00 List-Id: Matthew says "I am a proponent of Ada 95, but I also realise that there is a LOT of C++ code out there. One thing that has occurred to me is that an automatic C++ to Ada 95 "thin" binding generator would allow a lot of C++ code to be used from within Ada 95 programs. It wouldn't be as good as having a hand-coded binding, but at least it would mean we don't miss out on some of the good C++ libraries out there." There are two issues here. First you need to architect the Ada 95 compiler so that interface to C++ is smooth. GNAT implements a number of pragmas for this purpose, and when these pragmas are used, it is possible to map Ada tagged types exactly into C++ classes. So this is the raw material for a C++ interface, then you need a binding generator. SGI currently has developed such a tool internally, which they have used to provide bindings for many of their large libraries such as Inventor, but they have not yet released this tool for external use (it is still under development).