Files
carbon-lang/toolchain/diagnostics/diagnostic_kind.cpp
T
Jon Ross-Perkins 3d90a85f24 Change DiagnosticKind to use EnumBase (#2532)
Although the implementation is similar in size, I think the consistency benefits are helpful. registry.def -> kind.def is also consistent with other implementations.

Also switching int32_t -> uint16_t because I think we it might be enough space (?). We use uint8_t elsewhere, but that's certainly going to be too small. Sticking with int32_t felt inconsistent.
2023-01-18 17:47:28 -08:00

15 lines
469 B
C++

// Part of the Carbon Language project, under the Apache License v2.0 with LLVM
// Exceptions. See /LICENSE for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#include "toolchain/diagnostics/diagnostic_kind.h"
namespace Carbon {
CARBON_DEFINE_ENUM_CLASS_NAMES(DiagnosticKind) = {
#define CARBON_DIAGNOSTIC_KIND(Name) CARBON_ENUM_CLASS_NAME_STRING(Name)
#include "toolchain/diagnostics/diagnostic_kind.def"
};
} // namespace Carbon