feat(solver-bootstrap): step 3 — core-ids-and-diagnostics
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
#pragma once
|
||||
|
||||
#include <optional>
|
||||
#include <string>
|
||||
|
||||
#include <fesa/core/source_location.hpp>
|
||||
|
||||
namespace fesa {
|
||||
|
||||
enum class DiagnosticStage {
|
||||
io,
|
||||
syntax,
|
||||
semantic,
|
||||
model,
|
||||
equation,
|
||||
solver,
|
||||
results,
|
||||
validation
|
||||
};
|
||||
|
||||
enum class Severity { warning, error };
|
||||
|
||||
struct Diagnostic final {
|
||||
DiagnosticStage stage;
|
||||
Severity severity;
|
||||
std::string code;
|
||||
std::string message;
|
||||
std::optional<SourceLocation> source;
|
||||
};
|
||||
|
||||
} // namespace fesa
|
||||
Reference in New Issue
Block a user