This commit is contained in:
@@ -35,13 +35,13 @@ namespace Porygon::Diagnostics {
|
||||
_diagnostics.clear();
|
||||
}
|
||||
|
||||
void Log(DiagnosticSeverity severity, DiagnosticCode code, unsigned int start, unsigned int length, std::vector<string> arguments = {});
|
||||
void Log(DiagnosticSeverity severity, DiagnosticCode code, unsigned int start, unsigned int length, const std::vector<string>& arguments = {});
|
||||
|
||||
void LogError(DiagnosticCode code, unsigned int start, unsigned int length, std::vector<string> arguments = {});
|
||||
void LogError(DiagnosticCode code, unsigned int start, unsigned int length, const std::vector<string>& arguments = {});
|
||||
|
||||
void LogWarning(DiagnosticCode code, unsigned int start, unsigned int length, std::vector<string> arguments = {});
|
||||
void LogWarning(DiagnosticCode code, unsigned int start, unsigned int length, const std::vector<string>& arguments = {});
|
||||
|
||||
void LogInfo(DiagnosticCode code, unsigned int start, unsigned int length, std::vector<string> arguments = {});
|
||||
void LogInfo(DiagnosticCode code, unsigned int start, unsigned int length, const std::vector<string>& arguments = {});
|
||||
|
||||
bool HasErrors();
|
||||
|
||||
@@ -52,6 +52,7 @@ namespace Porygon::Diagnostics {
|
||||
Diagnostic *GetDiagnosticAt(int position);
|
||||
|
||||
size_t GetLineFromPosition(size_t i);
|
||||
[[nodiscard]]
|
||||
inline size_t GetStartPositionForLine(size_t i){
|
||||
return _lineStarts[i];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user