From 73595f45889f7bb7adfa6bd946eadc7348f31f4b Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Mon, 11 Mar 2019 03:26:21 -0300 Subject: Change clang-format settings --- src/sirit.cpp | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) (limited to 'src/sirit.cpp') diff --git a/src/sirit.cpp b/src/sirit.cpp index 9112a80..84e752b 100644 --- a/src/sirit.cpp +++ b/src/sirit.cpp @@ -4,16 +4,17 @@ * Lesser General Public License version 3 or any later version. */ -#include "sirit/sirit.h" +#include +#include #include "common_types.h" #include "op.h" +#include "sirit/sirit.h" #include "stream.h" -#include -#include namespace Sirit { -template static void WriteSet(Stream& stream, const T& set) { +template +static void WriteSet(Stream& stream, const T& set) { for (const auto& item : set) { item->Write(stream); } @@ -73,15 +74,13 @@ void Module::AddCapability(spv::Capability capability) { capabilities.insert(capability); } -void Module::SetMemoryModel(spv::AddressingModel addressing_model, - spv::MemoryModel memory_model) { +void Module::SetMemoryModel(spv::AddressingModel addressing_model, spv::MemoryModel memory_model) { this->addressing_model = addressing_model; this->memory_model = memory_model; } void Module::AddEntryPoint(spv::ExecutionModel execution_model, Id entry_point, - const std::string& name, - const std::vector& interfaces) { + const std::string& name, const std::vector& interfaces) { auto op{std::make_unique(spv::Op::OpEntryPoint)}; op->Add(static_cast(execution_model)); op->Add(entry_point); @@ -91,7 +90,7 @@ void Module::AddEntryPoint(spv::ExecutionModel execution_model, Id entry_point, } void Module::AddExecutionMode(Id entry_point, spv::ExecutionMode mode, - const std::vector& literals) { + const std::vector& literals) { auto op{std::make_unique(spv::Op::OpExecutionMode)}; op->Add(entry_point); op->Add(static_cast(mode)); @@ -121,9 +120,8 @@ Id Module::AddCode(spv::Op opcode, std::optional id) { } Id Module::AddDeclaration(std::unique_ptr op) { - const auto& found{ - std::find_if(declarations.begin(), declarations.end(), - [&op](const auto& other) { return *other == *op; })}; + const auto& found{std::find_if(declarations.begin(), declarations.end(), + [&op](const auto& other) { return *other == *op; })}; if (found != declarations.end()) { return found->get(); } -- cgit v1.2.3