Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions UnitTest/tests/smartViewTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@
namespace SmartViewTest
{
#define TEST(PARSERTYPE, NAME, NUM) \
TEST_METHOD(PARSERTYPE##_##NUM) \
{ \
test(parserType::PARSERTYPE, IDR_SV##NAME##NUM##IN, IDR_SV##NAME##NUM##OUT); \
}
TEST_METHOD(PARSERTYPE##_##NUM) { test(parserType::PARSERTYPE, IDR_SV##NAME##NUM##IN, IDR_SV##NAME##NUM##OUT); }

TEST_CLASS(SmartViewTest)
{
Expand Down
2 changes: 1 addition & 1 deletion core/mapi/mapiFunctions.h
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ namespace mapi

#pragma warning(push)
#pragma warning( \
disable : 26476) // Warning C26476 Expression/symbol '' uses a naked union '' with multiple type pointers: Use variant instead (type.7).
disable : 26476) // Warning C26476 Expression/symbol '' uses a naked union '' with multiple type pointers: Use variant instead (type.7).
inline const SBinary& getBin(_In_ const _SPropValue* prop) noexcept
{
if (!prop) assert(false);
Expand Down
4 changes: 0 additions & 4 deletions scripts/clang.bat

This file was deleted.

26 changes: 26 additions & 0 deletions scripts/clang.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
$vsRoot = & "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -property installationPath
$vcInstallDir = Join-Path $vsRoot "VC"
$clangdir = Join-Path $vcInstallDir "Tools\Llvm\bin\clang-format.exe"

# Check if VC install directory was found
if ($null -eq $vcInstallDir) {
Write-Host "Visual C++ installation directory not found."
}

if ($null -eq $clangdir) {
Write-Host "clang not found."
}

Push-Location ..

Write-Host "Formatting C++ headers"
Get-ChildItem -Recurse -Filter *.h | Where-Object { $_.DirectoryName -notlike "*include*" } | ForEach-Object {
& $clangdir -i $_.FullName
}

Write-Host "Formatting C++ sources"
Get-ChildItem -Recurse -Filter *.cpp | ForEach-Object {
& $clangdir -i $_.FullName
}

Pop-Location