1349cc55cSDimitry Andric //===--- CLWarnings.h - Maps some cl.exe warning ids -----------*- C++ -*-===// 2349cc55cSDimitry Andric // 3349cc55cSDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4349cc55cSDimitry Andric // See https://llvm.org/LICENSE.txt for license information. 5349cc55cSDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6349cc55cSDimitry Andric // 7349cc55cSDimitry Andric //===----------------------------------------------------------------------===// 8349cc55cSDimitry Andric 9349cc55cSDimitry Andric #ifndef LLVM_CLANG_BASIC_CLWARNINGS_H 10349cc55cSDimitry Andric #define LLVM_CLANG_BASIC_CLWARNINGS_H 11349cc55cSDimitry Andric 12*bdd1243dSDimitry Andric #include <optional> 13349cc55cSDimitry Andric 14349cc55cSDimitry Andric namespace clang { 15349cc55cSDimitry Andric 16349cc55cSDimitry Andric namespace diag { 17349cc55cSDimitry Andric enum class Group; 18349cc55cSDimitry Andric } 19349cc55cSDimitry Andric 20349cc55cSDimitry Andric /// For cl.exe warning IDs that cleany map to clang diagnostic groups, 21349cc55cSDimitry Andric /// returns the corresponding group. Else, returns an empty Optional. 22*bdd1243dSDimitry Andric std::optional<diag::Group> diagGroupFromCLWarningID(unsigned); 23349cc55cSDimitry Andric 24349cc55cSDimitry Andric } // end namespace clang 25349cc55cSDimitry Andric 26349cc55cSDimitry Andric #endif // LLVM_CLANG_BASIC_CLWARNINGS_H 27