]> granicus.if.org Git - clang/commitdiff
The prefix 'Ms-' should be 'MS-'
authorDavid Majnemer <david.majnemer@gmail.com>
Mon, 2 Feb 2015 19:30:52 +0000 (19:30 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Mon, 2 Feb 2015 19:30:52 +0000 (19:30 +0000)
Clang is otherwise consistent that Microsoft be abbreviated as MS, not
Ms.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@227842 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Basic/Attr.td
include/clang/Basic/AttrDocs.td
include/clang/Basic/DiagnosticOptions.h
lib/AST/Decl.cpp
lib/CodeGen/CGClass.cpp
lib/Frontend/CompilerInvocation.cpp
lib/Frontend/TextDiagnostic.cpp
lib/Sema/SemaAttr.cpp
lib/Sema/SemaDeclAttr.cpp

index 7245e49da8cae8242f5379c0365567aecbede620..5171b0c63e658ce178e1d58b90e075971fcd1ccc 100644 (file)
@@ -1761,17 +1761,17 @@ def TypeTagForDatatype : InheritableAttr {
 
 // Microsoft-related attributes
 
-def MsNoVTable : InheritableAttr {
+def MSNoVTable : InheritableAttr {
   let Spellings = [Declspec<"novtable">];
   let Subjects = SubjectList<[CXXRecord]>;
-  let Documentation = [MsNoVTableDocs];
+  let Documentation = [MSNoVTableDocs];
 }
 
-def MsProperty : IgnoredAttr {
+def : IgnoredAttr {
   let Spellings = [Declspec<"property">];
 }
 
-def MsStruct : InheritableAttr {
+def MSStruct : InheritableAttr {
   let Spellings = [GCC<"ms_struct">];
   let Subjects = SubjectList<[Record]>;
   let Documentation = [Undocumented];
index 933bc3628b92f261d3d089c22f50cc5fb182a902..64e4cea5b6f77ea8e3bd6f47e1843a44475d64a7 100644 (file)
@@ -1253,7 +1253,7 @@ an error:
 }];
 }
 
-def MsNoVTableDocs : Documentation {
+def MSNoVTableDocs : Documentation {
   let Category = DocCatType;
   let Content = [{
 This attribute can be added to a class declaration or definition to signal to
index 058e00f73e7710f29fadf6c95bf89d547e455b96..a16c7747cec373f9369d3b68d02cd46e1a02aa2b 100644 (file)
@@ -27,7 +27,7 @@ enum OverloadsShown : unsigned {
 /// \brief Options for controlling the compiler diagnostics engine.
 class DiagnosticOptions : public RefCountedBase<DiagnosticOptions>{
 public:
-  enum TextDiagnosticFormat { Clang, Msvc, Vi };
+  enum TextDiagnosticFormat { Clang, MSVC, Vi };
 
   // Default values.
   enum { DefaultTabStop = 8, MaxTabStop = 100,
index e43c28af9b699b01c612eeb13bda69ee55aeba04..9988c71d9789e5ff820153c40f0220466f00e6bb 100644 (file)
@@ -3589,7 +3589,7 @@ void RecordDecl::completeDefinition() {
 /// This which can be turned on with an attribute, pragma, or the
 /// -mms-bitfields command-line option.
 bool RecordDecl::isMsStruct(const ASTContext &C) const {
-  return hasAttr<MsStructAttr>() || C.getLangOpts().MSBitfields == 1;
+  return hasAttr<MSStructAttr>() || C.getLangOpts().MSBitfields == 1;
 }
 
 static bool isFieldOrIndirectField(Decl::Kind K) {
index 459b7742a26ae09556a985e3f6b05d6711fee2ea..2e2b420740be4b58066be2c8af2ea394a159cf8e 100644 (file)
@@ -1954,7 +1954,7 @@ CodeGenFunction::InitializeVTablePointer(BaseSubobject Base,
   // Don't initialize the vtable pointer if the class is marked with the
   // 'novtable' attribute.
   if ((RD == VTableClass || RD == NearestVBase) &&
-      VTableClass->hasAttr<MsNoVTableAttr>())
+      VTableClass->hasAttr<MSNoVTableAttr>())
     return;
 
   // Compute the address point.
index ab5c8f81686f8bf77dcd5b29e59cbf4c32c0969f..b5685d81f9da1d0321f87f7f2154c5bf3aca907d 100644 (file)
@@ -709,9 +709,9 @@ bool clang::ParseDiagnosticArgs(DiagnosticOptions &Opts, ArgList &Args,
   if (Format == "clang")
     Opts.setFormat(DiagnosticOptions::Clang);
   else if (Format == "msvc")
-    Opts.setFormat(DiagnosticOptions::Msvc);
+    Opts.setFormat(DiagnosticOptions::MSVC);
   else if (Format == "msvc-fallback") {
-    Opts.setFormat(DiagnosticOptions::Msvc);
+    Opts.setFormat(DiagnosticOptions::MSVC);
     Opts.CLFallbackMode = true;
   } else if (Format == "vi")
     Opts.setFormat(DiagnosticOptions::Vi);
index bbc99141f072edfc4ab71dbc35a62f7d877bca29..17e41f614a1ddd5d1384be69d0fd4527ec7eed98 100644 (file)
@@ -799,14 +799,14 @@ void TextDiagnostic::emitDiagnosticLoc(SourceLocation Loc, PresumedLoc PLoc,
   OS << PLoc.getFilename();
   switch (DiagOpts->getFormat()) {
   case DiagnosticOptions::Clang: OS << ':'  << LineNo; break;
-  case DiagnosticOptions::Msvc:  OS << '('  << LineNo; break;
+  case DiagnosticOptions::MSVC:  OS << '('  << LineNo; break;
   case DiagnosticOptions::Vi:    OS << " +" << LineNo; break;
   }
 
   if (DiagOpts->ShowColumn)
     // Compute the column number.
     if (unsigned ColNo = PLoc.getColumn()) {
-      if (DiagOpts->getFormat() == DiagnosticOptions::Msvc) {
+      if (DiagOpts->getFormat() == DiagnosticOptions::MSVC) {
         OS << ',';
         // Visual Studio 2010 or earlier expects column number to be off by one
         if (LangOpts.MSCompatibilityVersion &&
@@ -819,7 +819,7 @@ void TextDiagnostic::emitDiagnosticLoc(SourceLocation Loc, PresumedLoc PLoc,
   switch (DiagOpts->getFormat()) {
   case DiagnosticOptions::Clang:
   case DiagnosticOptions::Vi:    OS << ':';    break;
-  case DiagnosticOptions::Msvc:  OS << ") : "; break;
+  case DiagnosticOptions::MSVC:  OS << ") : "; break;
   }
 
   if (DiagOpts->ShowSourceRanges && !Ranges.empty()) {
index 76297977ea0e6f5c5d199e62031870f8576084cf..e3b66bf91348d23891a46c145cdeb5fff8385ee5 100644 (file)
@@ -131,7 +131,7 @@ void Sema::AddAlignmentAttributesForRecord(RecordDecl *RD) {
 
 void Sema::AddMsStructLayoutForRecord(RecordDecl *RD) {
   if (MSStructPragmaOn)
-    RD->addAttr(MsStructAttr::CreateImplicit(Context));
+    RD->addAttr(MSStructAttr::CreateImplicit(Context));
 
   // FIXME: We should merge AddAlignmentAttributesForRecord with
   // AddMsStructLayoutForRecord into AddPragmaAttributesForRecord, which takes
index 63695e847034afbc55691da593da4d2b3803262f..a05856ed7d3c1c5dc1b6c569f7df084e1ff5f8fa 100644 (file)
@@ -4689,11 +4689,11 @@ static void ProcessDeclAttribute(Sema &S, Scope *scope, Decl *D,
     break;
 
   // Microsoft attributes:
-  case AttributeList::AT_MsNoVTable:
-    handleSimpleAttribute<MsNoVTableAttr>(S, D, Attr);
+  case AttributeList::AT_MSNoVTable:
+    handleSimpleAttribute<MSNoVTableAttr>(S, D, Attr);
     break;
-  case AttributeList::AT_MsStruct:
-    handleSimpleAttribute<MsStructAttr>(S, D, Attr);
+  case AttributeList::AT_MSStruct:
+    handleSimpleAttribute<MSStructAttr>(S, D, Attr);
     break;
   case AttributeList::AT_Uuid:
     handleUuidAttr(S, D, Attr);