[aspectc-user] AC++ problem parsing certain template instantiations

Michael Stilkerich stilkerich at cs.fau.de
Wed Mar 3 10:39:41 CET 2010


Hi,

I stumbled across a problem of ac++ parsing class templates that are instantiated with an array-pointer symbol.

Consider the following examples, which is happily compiled by g++:

template <int *pool> class A {
};
int pool[20];
A<pool> inst;

-- or --

template <int pool[20]> class B {
};
int bpool[20];
B<bpool> b_inst;


Trying to compile this using AC++ gives me the following error:

ag++ --real-instances -c test.cpp
test.cpp:5: error: expected a constant as argument 1

On the other hand,

int pool;
A<&pool> inst;

works just fine.

Best,
-Michael

P.S.: The archives Link on http://www.aspectc.org/mailman/listinfo/aspectc-user seems to be broken.



More information about the aspectc-user mailing list