[all-commits] [llvm/llvm-project] 0cd308: [Clang][Sema] Don't say "is declared here" for inv...

Justin Bogner via All-commits all-commits at lists.llvm.org
Wed Dec 6 15:10:58 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0cd308aebcde8af4d8b11084a82c8e64b6a828c6
      https://github.com/llvm/llvm-project/commit/0cd308aebcde8af4d8b11084a82c8e64b6a828c6
  Author: Justin Bogner <mail at justinbogner.com>
  Date:   2023-12-06 (Wed, 06 Dec 2023)

  Changed paths:
    M clang/include/clang/Basic/DiagnosticSemaKinds.td
    M clang/include/clang/Sema/Sema.h
    M clang/lib/Sema/SemaDecl.cpp
    M clang/lib/Sema/SemaDeclCXX.cpp
    M clang/lib/Sema/SemaInit.cpp
    M clang/lib/Sema/SemaLambda.cpp
    M clang/lib/Sema/SemaTemplate.cpp
    M clang/lib/Sema/SemaType.cpp
    M clang/test/SemaHLSL/BuiltIns/vector-errors.hlsl

  Log Message:
  -----------
  [Clang][Sema] Don't say "is declared here" for invalid template locations

If a template is defined via an external AST source, it won't have a
location. When we emit warnings about misusing such templates we
shouldn't emit a "template is declared here" warning with no location,
as that's just confusing.

Reviewers: llvm-beanz, erichkeane, AaronBallman

Reviewed By: erichkeane, AaronBallman

Pull Request: https://github.com/llvm/llvm-project/pull/71264




More information about the All-commits mailing list