OOPSLA 2004 Boost workshop proposal

Dear Sir, Here is the abstract of our proposal for the OOPSLA2004 Boost Workshop. The proposal and the corresponding source is downloadable from http://gsd.web.elte.hu/Publications/GPCE_04/concept.pdf http://gsd.web.elte.hu/Publications/GPCE_04/concept.h Please forgive us the possible errors. Istvan Zolyomi scamel@elte.hu Zoltan Porkolab gsd@elte.hu ================================================================== Improving concept checking in Boost ABSTRACT To ensure the correctness of template based constructions in C++, constraints on template parameters are especially useful. Though C++ does not directly support checking requirements on template parameters, several solutions address this problem. Boost provides a comprehensive concept checking library that could be further advanced in many areas. In this paper we propose a different structure and an extended feature set to improve the Boost concept checking library into a general template introspection library. Our recommended solution takes the advantages of previous solutions, such as REQUIRE-like macros and static interfaces. On the lowest level, we suggest an orthogonal construction of elementary concepts instead of a predefined set of complex constraints. These basic concepts should return a boolean results instead of aborting compilation immediately, thus any metaprogramming tool could use the result of the check. Based on these building blocks, it is possible to express highly complex constraints using arbitrary logical expressions instead of the implicit conjunction used in all current concept checking libraries. Our solution is non-intrusive, relies only on standard C++ language features and implies no runtime overhead. Note that this is a shortened version of our paper 'Towards a general template introspection library' for GPCE'04 which can be downloaded from http://gsd.web.elte.hu/Publications/GPCE_04/introspection.pdf. In that article we also introduce a possible implementation detailed to the source-level. The sample source code can be downloaded from http://gsd.web.elte.hu/Publications/GPCE_04/concept.h. ==================================================================

"PORKOLAB Zoltan" wrote:
The [concept checking] proposal and the corresponding source is downloadable from http://gsd.web.elte.hu/Publications/GPCE_04/concept.pdf
Small note to chapter 3 intro: it is possible to check whether type is abstract. The technique was invented by Rani Sharoni and it will be included in Boost 1.32 as is_abstract<> type trait. It works only with newest compilers (e.g GCC3.4, VC7.1, Intel 7). /Pavel

On Sun, Sep 12, 2004 at 07:27:53AM +0200, Pavel Vozenilek wrote:
"PORKOLAB Zoltan" wrote:
The [concept checking] proposal and the corresponding source is downloadable from http://gsd.web.elte.hu/Publications/GPCE_04/concept.pdf
Small note to chapter 3 intro: it is possible to check whether type is abstract.
The technique was invented by Rani Sharoni and it will be included in Boost 1.32 as is_abstract<> type trait.
It works only with newest compilers (e.g GCC3.4, VC7.1, Intel 7).
Unfortunately, due to a compiler bug, it works with gcc 3.4 only if the class is _not_ a template specialization. See <URL:http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17232> for details. This bug probably won't be fixed in the gcc 3.4.x release series. Unless I misunderstood Giovanno Bajo's reply to my problem report then EDG based compilers also fail my testcase. Regards Christoph -- http://www.informatik.tu-darmstadt.de/TI/Mitarbeiter/cludwig.html LiDIA: http://www.informatik.tu-darmstadt.de/TI/LiDIA/Welcome.html
participants (3)
-
Christoph Ludwig
-
Pavel Vozenilek
-
PORKOLAB Zoltan