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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,9869a3929132e322 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,UTF8 Path: g2news2.google.com!postnews.google.com!i3g2000cwc.googlegroups.com!not-for-mail From: "bubble" Newsgroups: comp.lang.ada Subject: Re: pragma import ambiguity Date: 6 Sep 2006 09:39:30 -0700 Organization: http://groups.google.com Message-ID: <1157560770.358187.249610@i3g2000cwc.googlegroups.com> References: NNTP-Posting-Host: 210.58.159.145 Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1157560775 31644 127.0.0.1 (6 Sep 2006 16:39:35 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 6 Sep 2006 16:39:35 +0000 (UTC) User-Agent: G2/0.2 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: i3g2000cwc.googlegroups.com; posting-host=210.58.159.145; posting-account=62fXBQ0AAACuAtAY8PtyF-ogIBy_6k74 Xref: g2news2.google.com comp.lang.ada:6480 Date: 2006-09-06T09:39:30-07:00 List-Id: are you mean there are the same name symbols in a library? I assume your library is standard winapi and writing in C not C++. the C++ have name decoration problem to avoid the name decoration problem you "may" use external "C" to solve it. like #ifdef __cplusplus external "{" #end if __declspec(dllexport) int clear; int __declspec(dllexport) __stdcall clear(); #ifdef __cplusplus } end if I think your C/C++ compiler should allow to compiler it because C does not allow the same name in code. another way. you should create a def file and there are alias names in it. tmoran@acm.org =E5=AF=AB=E9=81=93=EF=BC=9A > One Ada compiler accepts this, another doesn't. I agree with the one that > objects. Are we wrong? > procedure testimp is > type logicopenm is ( clear, gl_and); > procedure clear(mask:integer); > pragma import(stdcall,clear,"glclear"); > begin > null; > end testimp;