Re: syntax suggestion
David Abrahams <[email protected]>
| Newsgroups | gmane.comp.lib.boost.langbinding |
|---|---|
| Message-ID | <[email protected]> |
Alexander Nasonov <[email protected]> writes: > On Thursday 04 March 2004 19:22, David Abrahams wrote: >> You can fix that by treating the result of the whole expression as an >> AST and evaluating it afterwards, but as I said, I worry about the >> compile-time costs. > > Major cases are already pointed out by Daniel: > > Daniel Wallin wrote: >> There are at least two cases where it won't work: >> >> struct A { void f(); } >> struct B : A {}; >> >> class_<B>("B") [ >> def("f", &B::f) // signature is void(A::*)() but A isn't >> // wrapped. >> ] >> >> and the most trivial.. >> >> class_<A>("A") [ >> def(constructor<>()) // Error, we need to explicitly mention >> ] // the wrapped type for every constructor >> I'm not sure what you're saying. Any of these can be handled perfectly well with lazy evaluation if you're willing to incur enough compile-time cost. I don't think we're understanding one another. -- Dave Abrahams Boost Consulting www.boost-consulting.com ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click