This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Heavy use of C++ templates in gcc-2.95 fails


Ulrich W. Eisenecker and Krzysztof Czarnecki developed
a C++ programming technique that they call
Template-Metaprogramming. Sample code is available from
http://www.prakinf.tu-ilmenau.de/~czarn/meta/metactrl
http://www.prakinf.tu-ilmenau.de/~czarn/meta/metaxmpl.cpp

And documentation from
http://home.t-online.de/home/Ulrich.Eisenecker/meta.htm

"metactrl" is a header file that provides control
structures and "metaxmpl.cpp" is an example using
metactrl. 
The header file claims, that

// This implementation uses member templates and has been tested with the
// Microsoft Visual C++ 5.0 compiler. Partial specialization and partial ordering of
// templates are not used.

The compilation failes with gcc-2.95. Could one of the
G++ wizards at least take a look at the problem? The code
looks fine to me, but I'm not a C++ language lawyer...

BTW, the concept is really interesting. You might want
to look at the code from pure curiosity. The authors will 
publish a book with "Addison Wesley" that might become a 
classic like "Design Patterns". It would be nice if one could
use their ideas and code with gcc.

-- 
Regards
       Joerg
GMD-IPSI, Dolivostr. 15, Zimmer 120, D-64293 Darmstadt
+49-6151-869-786 (Phone), -818 (FAX)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]