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
2 changes: 1 addition & 1 deletion .clang-tidy
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
Checks: 'clang-diagnostic-*,clang-analyzer-*,-*,bugprone-*,concurrency-*,performance-*,-macro*,readability-identifier-naming,-bugprone-exception-escape'
Checks: '-*,clang-diagnostic-*,clang-analyzer-*,bugprone-*,-bugprone-exception-escape,concurrency-*,performance-*,-macro*,readability-identifier-naming'
WarningsAsErrors: '*'
HeaderFilterRegex: './src/.*'
AnalyzeTemporaryDtors: false
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/analyzers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -148,4 +148,3 @@ jobs:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
sonar-scanner --define sonar.cfamily.build-wrapper-output="${{ env.BUILD_WRAPPER_OUT_DIR }}" --define sonar.scm.revision=${{ github.event.workflow_run.head_sha }} --define sonar.pullrequest.key=${{ steps.source-run-info.outputs.pullRequestNumber }} --define sonar.pullrequest.branch=${{ steps.source-run-info.outputs.sourceHeadBranch }} --define sonar.pullrequest.base=${{ steps.source-run-info.outputs.targetBranch }}

1 change: 0 additions & 1 deletion .github/workflows/comment_benchmarks_v2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,3 @@ jobs:
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./gh-pages

1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@ CMakeUserPresets.json

gen_docs/
gen_images/

33 changes: 10 additions & 23 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,16 @@ repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: trailing-whitespace
require_serial: true
# - id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: check-added-large-files # prevents giant files from being committed.
- id: check-case-conflict # checks for files that would conflict in case-insensitive filesystems.
- id: check-merge-conflict # checks for files that contain merge conflict strings.
- id: check-yaml # checks yaml files for parseable syntax.
- id: detect-private-key # detects the presence of private keys.
- id: end-of-file-fixer # ensures that a file is either empty, or ends with one newline.
- id: fix-byte-order-marker # removes utf-8 byte order marker.
- id: mixed-line-ending # replaces or checks mixed line ending.
- id: requirements-txt-fixer # sorts entries in requirements.txt.
- id: trailing-whitespace # trims trailing whitespace.

- repo: https://github.com/pre-commit/mirrors-clang-format
rev: 'v18.1.3'
Expand All @@ -23,21 +28,3 @@ repos:
args: ["-style=file", "-i"]
types_or: [c++, c]
require_serial: true

# - repo: local
# hooks:
# - id: compile_json
# name: compile_json
# entry: cmake --preset=ci-coverage-clang
# always_run: true
# require_serial: true
# pass_filenames: false
# language: system

# - repo: https://github.com/pocc/pre-commit-hooks
# rev: master
# hooks:
# - id: clang-tidy
# args: [--fix-errors, -config-file=.clang-tidy, "--checks=-*,bugprone-*,concurrency-*,performance-*", -p=build, ./src/*]
# # files: src
# entry: /usr/local/opt/llvm/bin/clang-tidy
2 changes: 1 addition & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
"ms-vscode.cmake-tools",
"cschlosser.doxdocgen"
]
}
}
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
"sonarlint.connectedMode.project": {
"projectKey": "victimsnino_ReactivePlusPlus"
}
}
}
2 changes: 1 addition & 1 deletion cmake/dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,4 @@ if (RPP_BUILD_BENCHMARKS)
set_target_properties(nanobench PROPERTIES CXX_CPPCHECK "")
set_target_properties(nanobench PROPERTIES FOLDER 3rdparty)

endif()
endif()
2 changes: 1 addition & 1 deletion cmake/dev-mode.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@

if(CMAKE_EXPORT_COMPILE_COMMANDS)
set(CMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES})
endif()
endif()
2 changes: 1 addition & 1 deletion cmake/install-config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ find_package(Threads REQUIRED)

include("${CMAKE_CURRENT_LIST_DIR}/RPPTargets.cmake")

check_required_components(RPP)
check_required_components(RPP)
2 changes: 1 addition & 1 deletion cmake/variables.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,4 @@ if (RPP_DEVELOPER_MODE)
if(RPP_ENABLE_COVERAGE)
include(cmake/coverage.cmake)
endif()
endif()
endif()
2 changes: 1 addition & 1 deletion docs/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -442,4 +442,4 @@ rpp::source::just(1,2,3)
| rpp::ops::flat_map([](const rpp::constraint::observable_of_type<int> auto& observable) { // or just `const auto& observable`
return observable | rpp::ops::filter([](int v){ return v % 2 == 0;});
});
```
```
2 changes: 1 addition & 1 deletion src/examples/rpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ add_subdirectory(linesfrombytes)

if (RPP_BUILD_SFML_CODE)
add_subdirectory(sfml)
endif()
endif()
2 changes: 1 addition & 1 deletion src/examples/rpp/basic/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ add_executable(basic_sample
)

target_link_libraries(basic_sample PRIVATE RPP::rpp)
set_target_properties(basic_sample PROPERTIES FOLDER Examples/rpp)
set_target_properties(basic_sample PROPERTIES FOLDER Examples/rpp)
2 changes: 1 addition & 1 deletion src/examples/rpp/basic/basic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ int main() // NOLINT(bugprone-exception-escape)
| rpp::operators::subscribe([](char v) { std::cout << v; });

return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ foreach(SOURCE ${FILES})
add_executable(${TARGET} ${SOURCE})
target_link_libraries(${TARGET} PRIVATE rpp)
set_target_properties(${TARGET} PROPERTIES FOLDER Examples/rpp/Doxygen)
endforeach()
endforeach()
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/as_blocking.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ int main() // NOLINT(bugprone-exception-escape)
std::cout << "done" << std::endl;
// output: COMPLETED done
//! [as_blocking]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/concat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ int main() // NOLINT(bugprone-exception-escape)
| rpp::operators::subscribe([](int v) { std::cout << v << ", "; }, [](const std::exception_ptr&) {}, []() { std::cout << "completed\n"; });
// Output: 1, 2, 1, 2, 3, completed
//! [concat_as_operator]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/connect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ int main() // NOLINT(bugprone-exception-escape)
// observer value 5
// DISPOSE
//! [connect]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/create.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@ int main() // NOLINT(bugprone-exception-escape)
.subscribe([](int v) { std::cout << v << std::endl; });
// Output: 42
//! [create with capture]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/defer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ int main() // NOLINT(bugprone-exception-escape)
// 0
// On complete
//! [defer mutable source]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/filter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ int main() // NOLINT(bugprone-exception-escape)
// Output: 0 2 4 6 8
//! [Filter]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/first.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ int main()
// Output: -x
//! [first_empty]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/from.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,4 @@ int main() // NOLINT(bugprone-exception-escape)
//! [from_callable]
}
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/interval.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ int main() // NOLINT(bugprone-exception-escape)
// emit 3 duration since start 25ms
// On complete
//! [defer from_iterable]
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/last.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ int main()
// Output: -x
//! [last empty]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/map.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ int main() // NOLINT(bugprone-exception-escape)
// Output: 42 VAL
//! [Changed type]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/repeat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ int main()
// Output: 1 2 3 1 2 3 1 2 3 1 completed
//! [repeat_infinitely]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/skip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ int main()
// Output: 2 3 4 5
//! [skip]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/start_wih.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ int main()
//! [start_with_observable_as_value]

return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/take.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ int main() // NOLINT(bugprone-exception-escape)
// Output: 0 1
//! [take]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/take_while.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ int main() // NOLINT(bugprone-exception-escape)
// Output: 0 1 2 3 4
//! [take_while]
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/doxygen/timeout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ int main() // NOLINT(bugprone-exception-escape)
});
//! [default]
}
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/linesfrombytes/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ linesfrombytes.cpp
)

target_link_libraries(linesfrombytes PRIVATE RPP::rpp)
set_target_properties(linesfrombytes PROPERTIES FOLDER Examples/rpp)
set_target_properties(linesfrombytes PROPERTIES FOLDER Examples/rpp)
2 changes: 1 addition & 1 deletion src/examples/rpp/linesfrombytes/linesfrombytes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,4 @@ int main() // NOLINT(bugprone-exception-escape)
// print result
lines | rpp::operators::subscribe([](const std::string& s) { std::cout << s << std::endl; });
return 0;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/long_chain/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ add_executable(long_chain_sample
)

target_link_libraries(long_chain_sample PRIVATE RPP::rpp)
set_target_properties(long_chain_sample PROPERTIES FOLDER Examples/rpp)
set_target_properties(long_chain_sample PROPERTIES FOLDER Examples/rpp)
2 changes: 1 addition & 1 deletion src/examples/rpp/package/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ find_package(RPP REQUIRED CONFIG)

add_executable(${PROJECT_NAME} ../basic/basic.cpp)
target_link_libraries(${PROJECT_NAME} PRIVATE RPP::rpp)
target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20)
target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20)
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
add_subdirectory(snake)
add_subdirectory(snake)
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ if (WIN32)
add_custom_command (TARGET ${TARGET} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:sfml-graphics> $<TARGET_FILE_DIR:${TARGET}>)
add_custom_command (TARGET ${TARGET} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:sfml-system> $<TARGET_FILE_DIR:${TARGET}>)
add_custom_command (TARGET ${TARGET} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:sfml-window> $<TARGET_FILE_DIR:${TARGET}>)
endif()
endif()
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/canvas.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ sf::Vector2u get_window_size(size_t rows_count, size_t cols_count)
{
return {static_cast<uint32_t>(static_cast<float>(cols_count) * (s_cell_size + s_gap_size)),
static_cast<uint32_t>(static_cast<float>(rows_count) * (s_cell_size + s_gap_size))};
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/canvas.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
#include "snake.hpp"

sf::RectangleShape get_rectangle_at(Coordinates location, sf::Color color);
sf::Vector2u get_window_size(size_t rows_count, size_t cols_count);
sf::Vector2u get_window_size(size_t rows_count, size_t cols_count);
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,4 +82,4 @@ int main()
}

return EXIT_SUCCESS;
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/snake.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -144,4 +144,4 @@ rpp::dynamic_observable<sf::RectangleShape> get_shapes_to_draw(const rpp::dynami
return get_presents_stream(events)
| rpp::ops::with_latest_from([](const auto&, const auto& v) { return v; }, drawable_objects)
| rpp::ops::switch_on_next();
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/snake.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

#include "utils.hpp"

rpp::dynamic_observable<sf::RectangleShape> get_shapes_to_draw(const rpp::dynamic_observable<CustomEvent>& events);
rpp::dynamic_observable<sf::RectangleShape> get_shapes_to_draw(const rpp::dynamic_observable<CustomEvent>& events);
2 changes: 1 addition & 1 deletion src/examples/rpp/sfml/snake/utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ auto get_presents_stream(const auto& events)
{
return events | rpp::ops::filter([](const CustomEvent& ev) { return std::holds_alternative<PresentEvent>(ev); })
| rpp::ops::map([](const CustomEvent& ev) { return std::get<PresentEvent>(ev); });
}
}
2 changes: 1 addition & 1 deletion src/examples/rpp/two_async_streams/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ add_executable(two_async_streams
)

target_link_libraries(two_async_streams PRIVATE RPP::rpp)
set_target_properties(two_async_streams PROPERTIES FOLDER Examples/rpp)
set_target_properties(two_async_streams PROPERTIES FOLDER Examples/rpp)
2 changes: 1 addition & 1 deletion src/examples/rpp/two_async_streams/two_async_streams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,4 @@ int main() // NOLINT(bugprone-exception-escape)
std::cout << "EXIT" << std::endl;

return 0;
}
}
1 change: 0 additions & 1 deletion src/examples/rppqt/basic/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,3 @@ add_executable(basic_rppqt basic_rppqt.cpp)
target_link_libraries(basic_rppqt PRIVATE rpp rppqt)
set_target_properties(basic_rppqt PROPERTIES FOLDER Examples/rppqt)
rpp_add_qt_support_to_executable(basic_rppqt)

2 changes: 1 addition & 1 deletion src/examples/rppqt/basic/basic_rppqt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,4 @@ int main(int argc, char* argv[])
window.show();

return app.exec();
}
}
1 change: 0 additions & 1 deletion src/examples/rppqt/doxygen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,3 @@ foreach(SOURCE ${FILES})
set_target_properties(${TARGET} PROPERTIES FOLDER Examples/rppqt/Doxygen)
rpp_add_qt_support_to_executable(${TARGET})
endforeach()

2 changes: 1 addition & 1 deletion src/rpp/rpp/defs.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@
#define RPP_NO_UNIQUE_ADDRESS [[msvc::no_unique_address]]
#else
#define RPP_NO_UNIQUE_ADDRESS [[no_unique_address]]
#endif
#endif
2 changes: 1 addition & 1 deletion src/rpp/rpp/disposables/callback_disposable.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,4 @@ namespace rpp
{
return disposable_wrapper::make<rpp::callback_disposable<std::decay_t<Fn>>>(std::forward<Fn>(invocable));
}
} // namespace rpp
} // namespace rpp
2 changes: 1 addition & 1 deletion src/rpp/rpp/disposables/details/base_disposable.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@ namespace rpp::details

using base_disposable = base_disposable_impl<interface_disposable>;
using base_composite_disposable = base_disposable_impl<interface_composite_disposable>;
} // namespace rpp::details
} // namespace rpp::details
Loading