diff options
| author | Ellie Hermaszewska <ellieh@nvidia.com> | 2024-10-29 14:49:26 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-29 14:49:26 +0800 |
| commit | f65d756bff8d4c5cbc15bd0322a2ae8e6b896a21 (patch) | |
| tree | ea1d61342cd29368e19135000ec2948813096205 /source/compiler-core/slang-downstream-compiler-set.cpp | |
| parent | a729c15e9dce9f5116a38afc66329ab2ca4cea54 (diff) | |
format
* format
* Minor test fixes
* enable checking cpp format in ci
Diffstat (limited to 'source/compiler-core/slang-downstream-compiler-set.cpp')
| -rw-r--r-- | source/compiler-core/slang-downstream-compiler-set.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/source/compiler-core/slang-downstream-compiler-set.cpp b/source/compiler-core/slang-downstream-compiler-set.cpp index ee09b994c..151c74b3e 100644 --- a/source/compiler-core/slang-downstream-compiler-set.cpp +++ b/source/compiler-core/slang-downstream-compiler-set.cpp @@ -19,7 +19,7 @@ Index DownstreamCompilerSet::_findIndex(const DownstreamCompilerDesc& desc) cons { const Index count = m_compilers.getCount(); for (Index i = 0; i < count; ++i) - { + { if (m_compilers[i]->getDesc() == desc) { return i; @@ -28,7 +28,8 @@ Index DownstreamCompilerSet::_findIndex(const DownstreamCompilerDesc& desc) cons return -1; } -IDownstreamCompiler* DownstreamCompilerSet::getCompiler(const DownstreamCompilerDesc& compilerDesc) const +IDownstreamCompiler* DownstreamCompilerSet::getCompiler( + const DownstreamCompilerDesc& compilerDesc) const { const Index index = _findIndex(compilerDesc); return index >= 0 ? m_compilers[index] : nullptr; @@ -37,13 +38,14 @@ IDownstreamCompiler* DownstreamCompilerSet::getCompiler(const DownstreamCompiler void DownstreamCompilerSet::getCompilers(List<IDownstreamCompiler*>& outCompilers) const { outCompilers.clear(); - outCompilers.addRange((IDownstreamCompiler*const*)m_compilers.begin(), m_compilers.getCount()); + outCompilers.addRange((IDownstreamCompiler* const*)m_compilers.begin(), m_compilers.getCount()); } bool DownstreamCompilerSet::hasSharedLibrary(ISlangSharedLibrary* lib) { - const Index foundIndex = m_sharedLibraries.findFirstIndex([lib](ISlangSharedLibrary* inLib) -> bool { return lib == inLib; }); - return(foundIndex >= 0); + const Index foundIndex = m_sharedLibraries.findFirstIndex( + [lib](ISlangSharedLibrary* inLib) -> bool { return lib == inLib; }); + return (foundIndex >= 0); } void DownstreamCompilerSet::addSharedLibrary(ISlangSharedLibrary* lib) @@ -94,4 +96,4 @@ void DownstreamCompilerSet::addCompiler(IDownstreamCompiler* compiler) } } -} +} // namespace Slang |
