commit | 47f5209a80c7c75592e87eb296d2b51e03208ae0 | [log] [tgz] |
---|---|---|
author | Steve Naroff <snaroff@apple.com> | Tue Jan 06 19:34:12 2009 +0000 |
committer | Steve Naroff <snaroff@apple.com> | Tue Jan 06 19:34:12 2009 +0000 |
tree | 1eb9b9e7a86af61b68996bd1b2e71be63fdea958 | |
parent | b8006e50bf378ddbab9601c1fa07f151ac538ff3 [diff] |
Another tweak to handle the MS extensions (<rdar://problem/5956221>). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@61821 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp index 3b65ee0..c4126f3 100644 --- a/lib/Parse/ParseDecl.cpp +++ b/lib/Parse/ParseDecl.cpp
@@ -1353,6 +1353,7 @@ case tok::less: return getLang().ObjC1; + case tok::kw___declspec: case tok::kw___cdecl: case tok::kw___stdcall: case tok::kw___fastcall:
diff --git a/lib/Parse/ParseTentative.cpp b/lib/Parse/ParseTentative.cpp index 11df2f4..a7c3e38 100644 --- a/lib/Parse/ParseTentative.cpp +++ b/lib/Parse/ParseTentative.cpp
@@ -626,6 +626,7 @@ return TPResult::True(); // Microsoft + case tok::kw___declspec: case tok::kw___cdecl: case tok::kw___stdcall: case tok::kw___fastcall:
diff --git a/test/Parser/MicrosoftExtensions.c b/test/Parser/MicrosoftExtensions.c index 6b097ab..beeef0a 100644 --- a/test/Parser/MicrosoftExtensions.c +++ b/test/Parser/MicrosoftExtensions.c
@@ -21,3 +21,8 @@ }; } +void *_alloca(int); + +void foo() { + __declspec(align(16)) int *buffer = (int *)_alloca(9); +}