diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2011-05-02 19:39:53 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2011-05-02 19:39:53 +0000 |
| commit | 01af97d3b23bded2b2b21af19bbc6e4cce49e5b3 (patch) | |
| tree | 64a10f4c4154739d4a8191d7e1b52ce497f4ebd6 /lib/Sema/JumpDiagnostics.cpp | |
| parent | c3b054d250cdca485c71845089c316e10610ebad (diff) | |
Notes
Diffstat (limited to 'lib/Sema/JumpDiagnostics.cpp')
| -rw-r--r-- | lib/Sema/JumpDiagnostics.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Sema/JumpDiagnostics.cpp b/lib/Sema/JumpDiagnostics.cpp index b73f0e9f1452..867d78fef6a7 100644 --- a/lib/Sema/JumpDiagnostics.cpp +++ b/lib/Sema/JumpDiagnostics.cpp @@ -149,6 +149,11 @@ static std::pair<unsigned,unsigned> return std::make_pair((unsigned) diag::note_protected_by_vla_typedef, 0); } + if (const TypeAliasDecl *TD = dyn_cast<TypeAliasDecl>(D)) { + if (TD->getUnderlyingType()->isVariablyModifiedType()) + return std::make_pair((unsigned) diag::note_protected_by_vla_type_alias, 0); + } + return std::make_pair(0U, 0U); } |
