Summary: This will be shared by include insertion/deletion library. Reviewers: ilya-biryukov Reviewed By: ilya-biryukov Subscribers: mgorny, klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D46758 llvm-svn: 332284
33 lines
1.0 KiB
C++
33 lines
1.0 KiB
C++
//===--- IncludeStyle.cpp - Style of C++ #include directives -----*- C++-*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#include "clang/Tooling/Core/IncludeStyle.h"
|
|
|
|
|
|
using clang::tooling::IncludeStyle;
|
|
|
|
namespace llvm {
|
|
namespace yaml {
|
|
|
|
void MappingTraits<IncludeStyle::IncludeCategory>::mapping(
|
|
IO &IO, IncludeStyle::IncludeCategory &Category) {
|
|
IO.mapOptional("Regex", Category.Regex);
|
|
IO.mapOptional("Priority", Category.Priority);
|
|
}
|
|
|
|
void ScalarEnumerationTraits<IncludeStyle::IncludeBlocksStyle>::enumeration(
|
|
IO &IO, IncludeStyle::IncludeBlocksStyle &Value) {
|
|
IO.enumCase(Value, "Preserve", IncludeStyle::IBS_Preserve);
|
|
IO.enumCase(Value, "Merge", IncludeStyle::IBS_Merge);
|
|
IO.enumCase(Value, "Regroup", IncludeStyle::IBS_Regroup);
|
|
}
|
|
|
|
} // namespace yaml
|
|
} // namespace llvm
|