Add string literals

This commit is contained in:
2020-05-17 20:30:57 +02:00
parent fc2870ca74
commit e1008b43a6
11 changed files with 152 additions and 48 deletions

18
include/token/errors.hpp Normal file
View File

@@ -0,0 +1,18 @@
#pragma once
#include <stdexcept>
#include <token/token.hpp>
namespace Token
{
struct TokenizationError : public std::exception
{
Token errorToken;
std::string errorMsg;
TokenizationError(Token const & token, std::string const & msg);
};
struct MissingEndOfString : public TokenizationError
{
MissingEndOfString(Token const & token);
};
}