aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/clang/AST/ASTContext.h1
-rw-r--r--include/clang/AST/ExprObjC.h9
-rw-r--r--include/clang/AST/X86Builtins.def3
-rw-r--r--include/clang/Basic/DiagnosticGroups.td11
-rw-r--r--include/clang/Basic/TokenKinds.def6
-rw-r--r--include/clang/Parse/AttributeList.h4
-rw-r--r--include/clang/Parse/Parser.h2
7 files changed, 25 insertions, 11 deletions
diff --git a/include/clang/AST/ASTContext.h b/include/clang/AST/ASTContext.h
index cad5487ea374..b02faa8ff378 100644
--- a/include/clang/AST/ASTContext.h
+++ b/include/clang/AST/ASTContext.h
@@ -696,7 +696,6 @@ public:
/// Compatibility predicates used to check assignment expressions.
bool typesAreCompatible(QualType, QualType); // C99 6.2.7p1
- bool typesAreBlockCompatible(QualType lhs, QualType rhs);
bool isObjCIdType(QualType T) const {
return T == ObjCIdType;
diff --git a/include/clang/AST/ExprObjC.h b/include/clang/AST/ExprObjC.h
index 51b99610cd9d..ef78c4081e34 100644
--- a/include/clang/AST/ExprObjC.h
+++ b/include/clang/AST/ExprObjC.h
@@ -34,6 +34,8 @@ public:
explicit ObjCStringLiteral(EmptyShell Empty)
: Expr(ObjCStringLiteralClass, Empty) {}
+ ObjCStringLiteral* Clone(ASTContext &C) const;
+
StringLiteral *getString() { return cast<StringLiteral>(String); }
const StringLiteral *getString() const { return cast<StringLiteral>(String); }
void setString(StringLiteral *S) { String = S; }
@@ -64,7 +66,8 @@ class ObjCEncodeExpr : public Expr {
public:
ObjCEncodeExpr(QualType T, QualType ET,
SourceLocation at, SourceLocation rp)
- : Expr(ObjCEncodeExprClass, T), EncType(ET), AtLoc(at), RParenLoc(rp) {}
+ : Expr(ObjCEncodeExprClass, T, ET->isDependentType(),
+ ET->isDependentType()), EncType(ET), AtLoc(at), RParenLoc(rp) {}
explicit ObjCEncodeExpr(EmptyShell Empty) : Expr(ObjCEncodeExprClass, Empty){}
@@ -103,6 +106,8 @@ public:
explicit ObjCSelectorExpr(EmptyShell Empty)
: Expr(ObjCSelectorExprClass, Empty) {}
+ ObjCSelectorExpr *Clone(ASTContext &C) const;
+
Selector getSelector() const { return SelName; }
void setSelector(Selector S) { SelName = S; }
@@ -143,6 +148,8 @@ public:
explicit ObjCProtocolExpr(EmptyShell Empty)
: Expr(ObjCProtocolExprClass, Empty) {}
+ ObjCProtocolExpr *Clone(ASTContext &C) const;
+
ObjCProtocolDecl *getProtocol() const { return Protocol; }
void setProtocol(ObjCProtocolDecl *P) { Protocol = P; }
diff --git a/include/clang/AST/X86Builtins.def b/include/clang/AST/X86Builtins.def
index 95d000346378..85381c0762d5 100644
--- a/include/clang/AST/X86Builtins.def
+++ b/include/clang/AST/X86Builtins.def
@@ -249,14 +249,11 @@ BUILTIN(__builtin_ia32_psradi128, "V4iV4ii", "")
BUILTIN(__builtin_ia32_pmaddwd128, "V8sV8sV8s", "")
BUILTIN(__builtin_ia32_monitor, "vv*UiUi", "")
BUILTIN(__builtin_ia32_mwait, "vUiUi", "")
-BUILTIN(__builtin_ia32_movshdup, "V4fV4f", "")
-BUILTIN(__builtin_ia32_movsldup, "V4fV4f", "")
BUILTIN(__builtin_ia32_lddqu, "V16ccC*", "")
BUILTIN(__builtin_ia32_palignr128, "V2LLiV2LLiV2LLii", "")
BUILTIN(__builtin_ia32_palignr, "V1LLiV1LLiV1LLis", "")
BUILTIN(__builtin_ia32_insertps128, "V4fV4fV4fi", "")
-BUILTIN(__builtin_ia32_loadlv4si, "V4iV2i*", "")
BUILTIN(__builtin_ia32_storelv4si, "vV2i*V2LLi", "")
BUILTIN(__builtin_ia32_pblendvb128, "V16cV16cV16cV16c", "")
diff --git a/include/clang/Basic/DiagnosticGroups.td b/include/clang/Basic/DiagnosticGroups.td
index 7c6b090a33a0..501807df77a3 100644
--- a/include/clang/Basic/DiagnosticGroups.td
+++ b/include/clang/Basic/DiagnosticGroups.td
@@ -85,9 +85,10 @@ def Trigraphs : DiagGroup<"trigraphs">;
def : DiagGroup<"type-limits">;
def Uninitialized : DiagGroup<"uninitialized">;
def UnknownPragmas : DiagGroup<"unknown-pragmas">;
-def : DiagGroup<"unused-function">;
-def : DiagGroup<"unused-label">;
-def : DiagGroup<"unused-parameter">;
+def UnusedArgument : DiagGroup<"unused-argument">;
+def UnusedFunction : DiagGroup<"unused-function">;
+def UnusedLabel : DiagGroup<"unused-label">;
+def UnusedParameter : DiagGroup<"unused-parameter">;
def UnusedValue : DiagGroup<"unused-value">;
def UnusedVariable : DiagGroup<"unused-variable">;
def : DiagGroup<"variadic-macros">;
@@ -98,6 +99,10 @@ def : DiagGroup<"write-strings">;
// Aggregation warning settings.
+def Unused : DiagGroup<"unused",
+ [UnusedArgument, UnusedFunction, UnusedLabel,
+ UnusedParameter, UnusedValue, UnusedVariable]>;
+
// Format settings.
def Format : DiagGroup<"format", [FormatExtraArgs, FormatZeroLength, NonNull]>;
def FormatSecurity : DiagGroup<"format-security", [Format]>;
diff --git a/include/clang/Basic/TokenKinds.def b/include/clang/Basic/TokenKinds.def
index 9b65288f68e1..497b1884a3d8 100644
--- a/include/clang/Basic/TokenKinds.def
+++ b/include/clang/Basic/TokenKinds.def
@@ -341,7 +341,6 @@ ALIAS("__attribute__", __attribute, KEYALL)
ALIAS("__const" , const , KEYALL)
ALIAS("__const__" , const , KEYALL)
ALIAS("__alignof__" , __alignof , KEYALL)
-ALIAS("_asm" , asm , KEYMS)
ALIAS("__asm" , asm , KEYALL)
ALIAS("__asm__" , asm , KEYALL)
ALIAS("__complex" , _Complex , KEYALL)
@@ -359,6 +358,11 @@ ALIAS("__typeof__" , typeof , KEYALL)
ALIAS("__volatile" , volatile , KEYALL)
ALIAS("__volatile__" , volatile , KEYALL)
+// Microsoft extensions which should be disabled in strict conformance mode
+ALIAS("_asm" , asm , KEYMS)
+ALIAS("_cdecl" , __cdecl , KEYMS)
+ALIAS("_fastcall" , __fastcall , KEYMS)
+ALIAS("_stdcall" , __stdcall , KEYMS)
//===----------------------------------------------------------------------===//
// Objective-C @-preceeded keywords.
diff --git a/include/clang/Parse/AttributeList.h b/include/clang/Parse/AttributeList.h
index 8225c9d33abb..26cebf0915b4 100644
--- a/include/clang/Parse/AttributeList.h
+++ b/include/clang/Parse/AttributeList.h
@@ -38,13 +38,14 @@ class AttributeList {
ActionBase::ExprTy **Args;
unsigned NumArgs;
AttributeList *Next;
+ bool DeclspecAttribute;
AttributeList(const AttributeList &); // DO NOT IMPLEMENT
void operator=(const AttributeList &); // DO NOT IMPLEMENT
public:
AttributeList(IdentifierInfo *AttrName, SourceLocation AttrLoc,
IdentifierInfo *ParmName, SourceLocation ParmLoc,
ActionBase::ExprTy **args, unsigned numargs,
- AttributeList *Next);
+ AttributeList *Next, bool declspec = false);
~AttributeList();
enum Kind { // Please keep this list alphabetized.
@@ -103,6 +104,7 @@ public:
IdentifierInfo *getName() const { return AttrName; }
SourceLocation getLoc() const { return AttrLoc; }
IdentifierInfo *getParameterName() const { return ParmName; }
+ bool isDeclspecAttribute() const { return DeclspecAttribute; }
Kind getKind() const { return getKind(getName()); }
static Kind getKind(const IdentifierInfo *Name);
diff --git a/include/clang/Parse/Parser.h b/include/clang/Parse/Parser.h
index 6218ade32300..6125fc633d07 100644
--- a/include/clang/Parse/Parser.h
+++ b/include/clang/Parse/Parser.h
@@ -1064,7 +1064,7 @@ private:
// EndLoc, if non-NULL, is filled with the location of the last token of
// the attribute list.
AttributeList *ParseAttributes(SourceLocation *EndLoc = 0);
- void FuzzyParseMicrosoftDeclSpec();
+ AttributeList *ParseMicrosoftDeclSpec();
void ParseTypeofSpecifier(DeclSpec &DS);
/// DeclaratorScopeObj - RAII object used in Parser::ParseDirectDeclarator to