From 3938450450950427492
X-Google-Thread: f78e5,b53358bee20fa31
X-Google-Attributes: gidf78e5,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
Path: g2news1.google.com!news1.google.com!news.glorb.com!peer1.news.newnet.co.uk!194.159.246.34.MISMATCH!peer-uk.news.demon.net!kibo.news.demon.net!news.demon.co.uk!demon!stump.algebra.com!devnull
From: michaelsafyan@aim.com (Michael Aaron Safyan)
Newsgroups: comp.std.c++
Subject: Re: Proposal for ISO C/C++: Extensions for Portable Compilation and
 Linkage
Date: Tue, 11 Dec 2007 15:57:40 GMT
Organization: Aioe.org NNTP Server
Lines: 47
Sender: mail2news@demon.net
Approved: fjh@cs.mu.oz.au (Fergus Henderson , moderator of comp.std.c++)
Message-ID: <fjmb5j$mpi$1@aioe.org>
References: <fjkjpg$7d6$1@aioe.org> <fjlbe4$r99$01$1@news.t-online.com>
NNTP-Posting-Host: news.news.demon.net
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: news.demon.co.uk 1197388673 22702 158.152.254.254 (11 Dec 2007 15:57:53 GMT)
X-Complaints-To: abuse@demon.net
NNTP-Posting-Date: Tue, 11 Dec 2007 15:57:53 +0000 (UTC)
X-Original-To: std-c++@mailman.ucar.edu
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-User-Agent: Thunderbird 2.0.0.9 (Macintosh/20071031)
X-Virus-Scanned: amavisd-new at ucar.edu
X-Path: comp-std-cpp-robomod!not-for-mail
X-Received: (from fjh@localhost)
	by mulga.csse.unimelb.edu.au (8.13.8+Sun/8.13.8/Submit) id lBBFveuW004616;
	Wed, 12 Dec 2007 02:57:40 +1100 (EST)
X-Delivered-To: std-c++@mailman.ucar.edu
X-Authentication-Warning: mulga.csse.unimelb.edu.au: fjh set sender to devnull@stump.algebra.com using -f
X-SMTP-Auth: no
X-Newsgroups: comp.std.c++
Xref: g2news1.google.com comp.std.c++:9790

Andre Kaufmann wrote:
> Michael Aaron Safyan wrote:
>> I would like to hear your feedback regarding this proposal:
>> http://michaelsafyan.fw.nu/publications/
> 
> Hi,
> adding such features to C++ would be a good idea. Though I don't like a 
> header file detection extension that much, simply because IMHO there 
> shouldn't be the need for header files at all.
> 
> I would generally drop the header idea in C++.
> 
> Why not simply:
> 
> #import "MyLibrary"
> 
> Which simply does:
> 
> a) Link to the library
> b) Get all information about the library, like exported classes
>    and functions from the library itself and store them in an auto
>    generated code file
> 
> So if you want to use a library you simply would have to add a single 
> line of code.
> 
> Andre

1.) Objective-C uses "#import", so this would break Objective-C and 
Objective-C++.

2.) It would still be necessary to know whether "MyLibrary" exists 
(unless this hypothetical import always succeeds), and it would still be 
necessary to detect the declarations associated with the library.

3.) What you propose can be accomplished at runtime using "dlopen" or 
"LoadLibrary". However, it is often necessary to know at compile-time 
whether a library is available.

Thank you, though, for the feedback.

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]



