Douglas Gregor | 025291b | 2010-07-01 00:21:21 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -fsyntax-only -verify %s |
| 2 | |
| 3 | // <rdar://problem/8124080> |
| 4 | template<typename _Alloc> class allocator; |
| 5 | template<class _CharT> struct char_traits; |
| 6 | template<typename _CharT, typename _Traits = char_traits<_CharT>, |
| 7 | typename _Alloc = allocator<_CharT> > |
| 8 | class basic_string; |
| 9 | template<typename _CharT, typename _Traits, typename _Alloc> |
| 10 | const typename basic_string<_CharT, _Traits, _Alloc>::size_type |
| 11 | basic_string<_CharT, _Traits, _Alloc>::_Rep::_S_max_size // expected-error{{no member named '_Rep' in 'basic_string<_CharT, _Traits, _Alloc>'}} |
| 12 | = (((npos - sizeof(_Rep_base))/sizeof(_CharT)) - 1) / 4; |
| 13 | |
| 14 | // PR7118 |
| 15 | template<typename T> |
| 16 | class Foo { |
| 17 | class Bar; |
| 18 | void f() { |
| 19 | Bar i; |
| 20 | } |
| 21 | }; |