2009-12-30 08:20:14 +08:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
|
|
|
|
|
|
|
// PR5908
|
|
|
|
template <typename Iterator>
|
|
|
|
void Test(Iterator it) {
|
|
|
|
*(it += 1);
|
|
|
|
}
|
2010-01-16 00:21:02 +08:00
|
|
|
|
|
|
|
namespace PR6045 {
|
|
|
|
template<unsigned int r>
|
|
|
|
class A
|
|
|
|
{
|
|
|
|
static const unsigned int member = r;
|
|
|
|
void f();
|
|
|
|
};
|
|
|
|
|
|
|
|
template<unsigned int r>
|
|
|
|
const unsigned int A<r>::member;
|
|
|
|
|
|
|
|
template<unsigned int r>
|
|
|
|
void A<r>::f()
|
|
|
|
{
|
|
|
|
unsigned k;
|
|
|
|
(void)(k % member);
|
|
|
|
}
|
|
|
|
}
|