aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/src/vcpkg_Enums.cpp
blob: 5e698659db12eac8dd759f9c8e8975bde2feb838 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "pch.h"
#include "vcpkg_Enums.h"
#include "vcpkg_Checks.h"

namespace vcpkg::Enums
{
    std::string nullvalue_toString(const std::string& enum_name)
    {
        return Strings::format("%s_NULLVALUE", enum_name);
    }

    void nullvalue_used(const std::string& enum_name)
    {
        Checks::exit_with_message("NULLVALUE of enum %s was used", enum_name);
    }

    void unreachable(const std::string& enum_name)
    {
        Checks::exit_with_message("Unreachable code for enum, %s", enum_name);
    }
}