diff options
author | George L. Albany <Megacake1234@gmail.com> | 2024-06-18 19:43:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-18 19:43:20 +0200 |
commit | 8b623bf4087aa360842ad31145d4ab6946cee9aa (patch) | |
tree | f15ebc47d6bf370031af28e4bb4814ae30ef46e1 /src/openvic-dataloader/v2script/ParseState.hpp | |
parent | 7b521d6023113372cf6b02e562828273c4040f0e (diff) | |
parent | b0c3ba3f91926b0c95625bdbf4aab69269130b13 (diff) |
Merge pull request #46 from OpenVicProject/fix/char-detection
Add runtime encoding detection and conversion
Diffstat (limited to 'src/openvic-dataloader/v2script/ParseState.hpp')
-rw-r--r-- | src/openvic-dataloader/v2script/ParseState.hpp | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/src/openvic-dataloader/v2script/ParseState.hpp b/src/openvic-dataloader/v2script/ParseState.hpp index 8e29bf5..954e39d 100644 --- a/src/openvic-dataloader/v2script/ParseState.hpp +++ b/src/openvic-dataloader/v2script/ParseState.hpp @@ -1,23 +1,24 @@ #pragma once -#include <openvic-dataloader/File.hpp> -#include <openvic-dataloader/ParseState.hpp> #include <openvic-dataloader/v2script/AbstractSyntaxTree.hpp> #include <lexy/encoding.hpp> +#include "../openvic-dataloader/ParseState.hpp" +#include "AbstractSyntaxTree.hpp" +#include "File.hpp" +#include "detail/InternalConcepts.hpp" + namespace ovdl::v2script::ast { - using File = ovdl::BasicFile<lexy::default_encoding, Node>; - struct AbstractSyntaxTree : ovdl::BasicAbstractSyntaxTree<File, FileTree> { - using BasicAbstractSyntaxTree::BasicAbstractSyntaxTree; + + struct FileAbstractSyntaxTree : ovdl::BasicAbstractSyntaxTree<ovdl::BasicFile<Node>, FileTree> { + using ovdl::BasicAbstractSyntaxTree<ovdl::BasicFile<Node>, FileTree>::BasicAbstractSyntaxTree; std::string make_list_visualizer() const; std::string make_native_visualizer() const; }; - using ParseState = ovdl::ParseState<AbstractSyntaxTree>; + using ParseState = ovdl::ParseState<FileAbstractSyntaxTree>; - static_assert(IsFile<ast::File>, "File failed IsFile concept"); - static_assert(IsAst<ast::AbstractSyntaxTree>, "AbstractSyntaxTree failed IsAst concept"); - static_assert(IsParseState<ast::ParseState>, "ParseState failed IsParseState concept"); + static_assert(detail::IsParseState<ast::ParseState>, "ParseState failed IsParseState concept"); }
\ No newline at end of file |