Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ if(PROJECT_IS_TOP_LEVEL)
include(CTest) # sets BUILD_TESTING
endif()

add_subdirectory(modules/iris)
if(NOT DEFINED IRIS_ROOT)
set(IRIS_ROOT "${CMAKE_CURRENT_LIST_DIR}/modules/iris")
endif()

add_subdirectory("${IRIS_ROOT}")


# -----------------------------------------------------------------
Expand Down Expand Up @@ -97,6 +101,9 @@ foreach(dep IN LISTS iris_x4_boost_deps)
add_subdirectory(../${dep} build_deps/${dep})
endforeach()

set_target_properties(boost_assert PROPERTIES FOLDER "_deps")
set_target_properties(boost_core PROPERTIES FOLDER "_deps")

foreach(dep IN LISTS iris_x4_boost_deps)
target_link_libraries(iris_x4 INTERFACE Boost::${dep})
endforeach()
Expand Down
2 changes: 2 additions & 0 deletions test/x4/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ endfunction()

function(x4_define_test test_name)
iris_define_test(x4_${test_name} ${ARGN})
iris_define_test_headers(x4_${test_name} iris_x4_test.hpp)
target_link_libraries(x4_${test_name}_test PRIVATE Iris::X4)

if(MSVC)
Expand All @@ -27,6 +28,7 @@ endfunction()
function(x4_define_tests)
foreach(test_name IN LISTS ARGV)
x4_define_test(${test_name} ${test_name}.cpp)
set_target_properties(x4_${test_name}_test PROPERTIES FOLDER "test/x4")
endforeach()
endfunction()

Expand Down
2 changes: 1 addition & 1 deletion test/x4/actions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/numeric/int.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/alternative.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/auxiliary/attr.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/and_predicate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/numeric/int.hpp>
#include <iris/x4/operator/and_predicate.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/as.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/attr.hpp>
#include <iris/x4/auxiliary/eps.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/attr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/attr.hpp>
#include <iris/x4/numeric/int.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/attribute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/attr.hpp>
#include <iris/x4/auxiliary/eps.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/attribute_type_check.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/attr.hpp>
#include <iris/x4/auxiliary/eps.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/bool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#define IRIS_X4_UNICODE

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/directive/no_case.hpp>
#include <iris/x4/numeric/bool.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/char.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

#define IRIS_X4_UNICODE

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/char_class.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#define IRIS_X4_UNICODE

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/container_support.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/char/char.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/core/context.hpp>

Expand Down
2 changes: 1 addition & 1 deletion test/x4/debug.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

#define IRIS_X4_DEBUG

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/debug/error_reporting.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/difference.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/eoi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/eoi.hpp>

Expand Down
2 changes: 1 addition & 1 deletion test/x4/eol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/eol.hpp>

Expand Down
2 changes: 1 addition & 1 deletion test/x4/eps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/auxiliary/eps.hpp>
#include <iris/x4/operator/not_predicate.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/error_handler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/char/char.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/expect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# pragma warning(disable: 6262) // Function uses 'XXXXX' bytes of stack
#endif

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/negated_char.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/extract_int.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/numeric/utils/extract_int.hpp>

Expand Down
2 changes: 1 addition & 1 deletion test/x4/grammar.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>

Expand Down
2 changes: 1 addition & 1 deletion test/x4/grammar_linker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"
#include "grammar.hpp"

TEST_CASE("grammar")
Expand Down
2 changes: 1 addition & 1 deletion test/x4/int.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char_class.hpp>
#include <iris/x4/numeric/int.hpp>
Expand Down
9 changes: 4 additions & 5 deletions test/x4/test.hpp → test/x4/iris_x4_test.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#ifndef IRIS_X4_TEST_X4_TEST_HPP
#define IRIS_X4_TEST_X4_TEST_HPP
#ifndef IRIS_X4_TEST_IRIS_X4_TEST_HPP
#define IRIS_X4_TEST_IRIS_X4_TEST_HPP

/*=============================================================================
Copyright (c) 2001-2013 Joel de Guzman
Expand All @@ -11,13 +11,12 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include <iris/config.hpp>
#include "iris_test.hpp"

#include <iris/x4/core/parser.hpp>
#include <iris/x4/core/move_to.hpp>
#include <iris/x4/parse.hpp>

#include <catch2/catch_test_macros.hpp>

#include <iterator>
#include <string_view>
#include <type_traits>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/iterator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#define IRIS_X4_UNICODE

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/negated_char.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/kleene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/lexeme.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/list.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/lit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#define IRIS_X4_UNICODE

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/string/string.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/matches.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/directive/matches.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/no_case.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/directive/no_case.hpp>
#include <iris/x4/char/char.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/no_skip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/not_predicate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/numeric/int.hpp>
#include <iris/x4/operator/not_predicate.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/omit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/directive/omit.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/optional.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/string/string.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/parser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/core/parser.hpp>
#include <iris/x4/operator/sequence.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/plus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/char/char.hpp>
#include <iris/x4/char/char_class.hpp>
Expand Down
2 changes: 1 addition & 1 deletion test/x4/raw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
=============================================================================*/

#include "test.hpp"
#include "iris_x4_test.hpp"

#include <iris/x4/rule.hpp>
#include <iris/x4/auxiliary/eps.hpp>
Expand Down
Loading