1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 18:38:10 +00:00

JSSpecCompiler: Add converter from LibCpp's AST

This will effectively allow us to use C++ code as an input for the
compiler. This would be useful for testing, since otherwise we would
have had to specify tests as a spec-like XML, which is not exactly the
most developer-friendly experience.
This commit is contained in:
Dan Klishch 2023-09-13 01:42:40 -04:00 committed by Jelle Raaijmakers
parent 567b1f6e7c
commit 75fd28014c
3 changed files with 214 additions and 1 deletions

View file

@ -5,6 +5,7 @@ set(SOURCES
Compiler/GenericASTPass.cpp
Compiler/IfBranchMergingPass.cpp
Compiler/ReferenceResolvingPass.cpp
Parser/CppASTConverter.cpp
Parser/Lexer.cpp
Parser/ParseError.cpp
Parser/SpecParser.cpp
@ -14,6 +15,6 @@ set(SOURCES
main.cpp
)
lagom_tool(JSSpecCompiler LIBS LibMain LibXML)
lagom_tool(JSSpecCompiler LIBS LibCpp LibMain LibXML)
target_include_directories(JSSpecCompiler PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_compile_options(JSSpecCompiler PRIVATE -Wno-missing-field-initializers)