Enums::nullvalue_used() now requires LineInfo as first arg
MODIFY
include/vcpkg_Enums.h
include/vcpkg_Enums.h
#pragma once
#include <string>
+#include "LineInfo.h"
namespace vcpkg::Enums
{
std::string nullvalue_toString(const std::string& enum_name);
- __declspec(noreturn) void nullvalue_used(const std::string& enum_name);
+ __declspec(noreturn) void nullvalue_used(const LineInfo& line_info, const std::string& enum_name);
}

MODIFY
src/PostBuildLint_BuildPolicies.cpp
src/PostBuildLint_BuildPolicies.cpp
@@ -43,7 +43,7 @@ namespace vcpkg::PostBuildLint::BuildPolicies
case ONLY_RELEASE_CRT:
return CMAKE_VARIABLE_ONLY_RELEASE_CRT;
case NULLVALUE:
- Enums::nullvalue_used(ENUM_NAME);
+ Enums::nullvalue_used(VCPKG_LINE_INFO, ENUM_NAME);
default:
Checks::unreachable(VCPKG_LINE_INFO);
}

MODIFY
src/vcpkg_Enums.cpp
src/vcpkg_Enums.cpp
@@ -9,7 +9,7 @@ namespace vcpkg::Enums
return Strings::format("%s_NULLVALUE", enum_name);
}
- __declspec(noreturn) void nullvalue_used(const std::string& enum_name)
+ __declspec(noreturn) void nullvalue_used(const LineInfo& line_info, const std::string& enum_name)
{
Checks::exit_with_message("NULLVALUE of enum %s was used", enum_name);
}

Enums::nullvalue_used() now requires LineInfo as first arg