From 901c7de901617841d1608449c0ccfedd0cb46b6a Mon Sep 17 00:00:00 2001 From: Malcolm Parsons Date: Wed, 24 Jan 2018 10:26:09 +0000 Subject: [PATCH] Fix typos of occurred and occurrence git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@323316 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/ClangFormatStyleOptions.rst | 2 +- include/clang/Analysis/CloneDetection.h | 4 ++-- include/clang/Format/Format.h | 2 +- include/clang/Lex/VariadicMacroSupport.h | 2 +- include/clang/Tooling/Core/Diagnostic.h | 2 +- lib/Analysis/CloneDetection.cpp | 4 ++-- test/Driver/hexagon-hvx.c | 2 +- tools/clang-import-test/clang-import-test.cpp | 2 +- tools/scan-build-py/libscanbuild/analyze.py | 2 +- 9 files changed, 11 insertions(+), 11 deletions(-) diff --git a/docs/ClangFormatStyleOptions.rst b/docs/ClangFormatStyleOptions.rst index ec6a78ad67..ea43f19a3c 100644 --- a/docs/ClangFormatStyleOptions.rst +++ b/docs/ClangFormatStyleOptions.rst @@ -1590,7 +1590,7 @@ the configuration (without a prefix: ``Auto``). precedence over a matching enclosing function name for determining the language of the raw string contents. - If a canonical delimiter is specified, occurences of other delimiters for + If a canonical delimiter is specified, occurrences of other delimiters for the same language will be updated to the canonical if possible. There should be at most one specification per language and each delimiter diff --git a/include/clang/Analysis/CloneDetection.h b/include/clang/Analysis/CloneDetection.h index 051b923665..5ef4457018 100644 --- a/include/clang/Analysis/CloneDetection.h +++ b/include/clang/Analysis/CloneDetection.h @@ -351,7 +351,7 @@ struct FilenamePatternConstraint { /// Analyzes the pattern of the referenced variables in a statement. class VariablePattern { - /// Describes an occurence of a variable reference in a statement. + /// Describes an occurrence of a variable reference in a statement. struct VariableOccurence { /// The index of the associated VarDecl in the Variables vector. size_t KindID; @@ -362,7 +362,7 @@ class VariablePattern { : KindID(KindID), Mention(Mention) {} }; - /// All occurences of referenced variables in the order of appearance. + /// All occurrences of referenced variables in the order of appearance. std::vector Occurences; /// List of referenced variables in the order of appearance. /// Every item in this list is unique. diff --git a/include/clang/Format/Format.h b/include/clang/Format/Format.h index e5bf1f3ebe..bffa6ddac2 100644 --- a/include/clang/Format/Format.h +++ b/include/clang/Format/Format.h @@ -1395,7 +1395,7 @@ struct FormatStyle { /// precedence over a matching enclosing function name for determining the /// language of the raw string contents. /// - /// If a canonical delimiter is specified, occurences of other delimiters for + /// If a canonical delimiter is specified, occurrences of other delimiters for /// the same language will be updated to the canonical if possible. /// /// There should be at most one specification per language and each delimiter diff --git a/include/clang/Lex/VariadicMacroSupport.h b/include/clang/Lex/VariadicMacroSupport.h index cebaf15187..db1ce0e6be 100644 --- a/include/clang/Lex/VariadicMacroSupport.h +++ b/include/clang/Lex/VariadicMacroSupport.h @@ -55,7 +55,7 @@ namespace clang { /// Client code should call this function as soon as the Preprocessor has /// either completed lexing the macro's definition tokens, or an error - /// occured and the context is being exited. This function is idempotent + /// occurred and the context is being exited. This function is idempotent /// (might be explicitly called, and then reinvoked via the destructor). void exitScope() { Ident__VA_ARGS__->setIsPoisoned(true); diff --git a/include/clang/Tooling/Core/Diagnostic.h b/include/clang/Tooling/Core/Diagnostic.h index b4920d4fe4..c8307c88df 100644 --- a/include/clang/Tooling/Core/Diagnostic.h +++ b/include/clang/Tooling/Core/Diagnostic.h @@ -33,7 +33,7 @@ struct DiagnosticMessage { DiagnosticMessage(llvm::StringRef Message = ""); /// \brief Constructs a diagnostic message with anoffset to the diagnostic - /// within the file where the problem occured. + /// within the file where the problem occurred. /// /// \param Loc Should be a file location, it is not meaningful for a macro /// location. diff --git a/lib/Analysis/CloneDetection.cpp b/lib/Analysis/CloneDetection.cpp index 098803f9a4..3c64f14387 100644 --- a/lib/Analysis/CloneDetection.cpp +++ b/lib/Analysis/CloneDetection.cpp @@ -534,14 +534,14 @@ void VariablePattern::addVariableOccurence(const VarDecl *VarDecl, // First check if we already reference this variable for (size_t KindIndex = 0; KindIndex < Variables.size(); ++KindIndex) { if (Variables[KindIndex] == VarDecl) { - // If yes, add a new occurence that points to the existing entry in + // If yes, add a new occurrence that points to the existing entry in // the Variables vector. Occurences.emplace_back(KindIndex, Mention); return; } } // If this variable wasn't already referenced, add it to the list of - // referenced variables and add a occurence that points to this new entry. + // referenced variables and add a occurrence that points to this new entry. Occurences.emplace_back(Variables.size(), Mention); Variables.push_back(VarDecl); } diff --git a/test/Driver/hexagon-hvx.c b/test/Driver/hexagon-hvx.c index 171d586760..47f2c40faf 100644 --- a/test/Driver/hexagon-hvx.c +++ b/test/Driver/hexagon-hvx.c @@ -65,7 +65,7 @@ // RUN: 2>&1 | FileCheck -check-prefix=CHECK-HVXEQ %s // CHECK-HVXEQ: "-target-feature" "+hvxv62" -// Honor the last occured -mhvx=, -mhvx flag. +// Honor the last occurred -mhvx=, -mhvx flag. // RUN: %clang -c %s -### -target hexagon-unknown-elf -mv60 -mhvx=v62 -mhvx\ // RUN: 2>&1 | FileCheck -check-prefix=CHECK-HVXEQ-PRE %s // CHECK-HVXEQ-PRE-NOT: "-target-feature" "+hvxv62" diff --git a/tools/clang-import-test/clang-import-test.cpp b/tools/clang-import-test/clang-import-test.cpp index 1ea7ee3611..4871acdf36 100644 --- a/tools/clang-import-test/clang-import-test.cpp +++ b/tools/clang-import-test/clang-import-test.cpp @@ -327,7 +327,7 @@ llvm::Expected Parse(const std::string &Path, CG.GetModule()->print(llvm::outs(), nullptr); if (CI.getDiagnosticClient().getNumErrors()) return llvm::make_error( - "Errors occured while parsing the expression.", std::error_code()); + "Errors occurred while parsing the expression.", std::error_code()); return std::move(CI); } diff --git a/tools/scan-build-py/libscanbuild/analyze.py b/tools/scan-build-py/libscanbuild/analyze.py index b5614b5b6d..6c129bd7c6 100644 --- a/tools/scan-build-py/libscanbuild/analyze.py +++ b/tools/scan-build-py/libscanbuild/analyze.py @@ -317,7 +317,7 @@ def run(opts): return arch_check(opts) except Exception: - logging.error("Problem occured during analyzis.", exc_info=1) + logging.error("Problem occurred during analyzis.", exc_info=1) return None -- 2.40.0