Discussion:
[Rock-dev] Typelib and template arguments
Janosch Machowinski
2014-07-31 09:48:23 UTC
Permalink
Hi,
while working on the clang tlb generator, I stumbled over this typedef :
Found Typedef
Eigen::internal::traits<Eigen::CoeffBasedProduct<const
Eigen::Matrix<double, 3, 1, 2, 3, 1> &,
Eigen::Block<Eigen::Matrix<double, 4, 4, 0, 4, 4>, 1, 4, false, true>,
256> >::Index
for Canonical Type long

When passing the typedef name to Typelib, I get an 'Typelib::BadName'.
This is because typelib does not like the const qualifier and the reference.

But as we can't refer from the template arguments of the class to
content of
it and as bar<char> and bar<const char> generate two different instances,
this should be a valid name.

So general question, should we go for supporting this, or just ignore
anything with
a weired name ?

Greetings
Janosch
--
Dipl. Inf. Janosch Machowinski
SAR- & Sicherheitsrobotik

Universit?t Bremen
FB 3 - Mathematik und Informatik
AG Robotik
Robert-Hooke-Stra?e 1
28359 Bremen, Germany

Zentrale: +49 421 178 45-6611

Besuchsadresse der Nebengesch?ftstelle:
Robert-Hooke-Stra?e 5
28359 Bremen, Germany

Tel.: +49 421 178 45-6614
Empfang: +49 421 178 45-6600
Fax: +49 421 178 45-4150
E-Mail: jmachowinski at informatik.uni-bremen.de

Weitere Informationen: http://www.informatik.uni-bremen.de/robotik
Sylvain Joyeux
2014-08-01 18:00:14 UTC
Permalink
What typelib is not happy about is that types should start with a /
(but can contain spaces), and should not have spaces after the commas.
Moreover, the name separator is / not ::, so you want to add:

/Eigen/Matrix</double,3,1,2,3,1>

The reference is an issue though.

In general, the gccxml importer does not register typedefs like this,
but instead resolves the full name to the opaque name (i.e. the matrix
above is only seen by typelib as /Eigen/Vector3d).

Sylvain



On Thu, Jul 31, 2014 at 6:48 AM, Janosch Machowinski
Post by Janosch Machowinski
Hi,
Found Typedef
Eigen::internal::traits<Eigen::CoeffBasedProduct<const
Eigen::Matrix<double, 3, 1, 2, 3, 1> &,
Eigen::Block<Eigen::Matrix<double, 4, 4, 0, 4, 4>, 1, 4, false, true>,
256> >::Index
for Canonical Type long
When passing the typedef name to Typelib, I get an 'Typelib::BadName'.
This is because typelib does not like the const qualifier and the reference.
But as we can't refer from the template arguments of the class to
content of
it and as bar<char> and bar<const char> generate two different instances,
this should be a valid name.
So general question, should we go for supporting this, or just ignore
anything with
a weired name ?
Greetings
Janosch
--
Dipl. Inf. Janosch Machowinski
SAR- & Sicherheitsrobotik
Universit?t Bremen
FB 3 - Mathematik und Informatik
AG Robotik
Robert-Hooke-Stra?e 1
28359 Bremen, Germany
Zentrale: +49 421 178 45-6611
Robert-Hooke-Stra?e 5
28359 Bremen, Germany
Tel.: +49 421 178 45-6614
Empfang: +49 421 178 45-6600
Fax: +49 421 178 45-4150
E-Mail: jmachowinski at informatik.uni-bremen.de
Weitere Informationen: http://www.informatik.uni-bremen.de/robotik
_______________________________________________
Rock-dev mailing list
Rock-dev at dfki.de
http://www.dfki.de/mailman/cgi-bin/listinfo/rock-dev
Loading...