mirror of
https://github.com/ETLCPP/etl.git
synced 2026-10-30 19:07:11 +08:00
* Add docs and tutorial for etl::intrusive_avl_tree (#1608) * Add docs and tutorial for etl::intrusive_avl_tree Documents the intrusive AVL tree added in PR #1425: a full API reference page under Containers/Trees, and a tutorial demonstrating ordered access to intrusively-linked objects with unpredictable lifetimes, including move support and destructor-driven automatic removal from the tree. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * Add complexity shortcode and document its usage Introduces a {{< complexity >}} Hugo shortcode (with light/dark styling for constant/logarithmic/linear/linearithmic/polynomial/exponential classes) for rendering Big-O complexity inline, applies it throughout the intrusive_avl_tree API reference in place of raw "O(...)" text, and documents the Description/Complexity structure and supported classes in DOCUMENTATION.md. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * Fix issues found by @CodeRabbit * Put complexity notes on their own lines in intrusive_avl_tree docs Move the complexity shortcode from the inline "**Complexity:**" label to its own line under a "**Complexity**" label. Notes that give several alternatives (e.g. amortized vs. worst-case) now show each one on a separate line. Update the guideline in DOCUMENTATION.md to match. * Update complexity examples in DOCUMENTATION.md Add the hard line break after the "**Complexity**" label in the example, and rewrite the list of supported complexity classes in the new two-line format, including an example with several alternatives. * Add logarithmic complexity example to DOCUMENTATION.md --------- Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> Co-authored-by: John Wellbelove <jwellbelove@users.noreply.github.com> * Updated sponsors pages * Refactor the documentation css to group styles for light and dark themes * Update Codacy badge in README.md Updated Codacy badge link to reflect new project status. * Fix Codacy badge display * refresh codacy integration status * Expose more Zephyr Kconfigs for error handling (#1622) * zephyr: make `ETL_DEBUG` default to on if Zephyr assertions are enabled this is the more appropriate default: ETL_DEBUG controls some container assertions, so it should follow the Zephyr assertions by default * zephyr: expose new error-checking configs * zephyr: add Kconfig choices for error handling * Fix find and rfind position handling in string and string_view * Default the rfind string_view position to npos The string_view overload defaulted pos to 0, so rfind(view) only found a match at the start of the string. The other rfind overloads and std::basic_string use npos. --------- Co-authored-by: Sergei <sergej.shirokov@gmail.com> Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> Co-authored-by: John Wellbelove <jwellbelove@users.noreply.github.com> Co-authored-by: John Wellbelove <john.wellbelove@etlcpp.com> Co-authored-by: Eden Frosst <edenfrosst@gmail.com>
86 lines
2.3 KiB
Plaintext
86 lines
2.3 KiB
Plaintext
config ETL
|
|
bool "ETL (Embedded Template Library)"
|
|
depends on CPP
|
|
help
|
|
This option enables the 'ETL' library.
|
|
|
|
if ETL
|
|
|
|
config ETL_DEBUG
|
|
bool "Build ETL with debugging checks"
|
|
default y if ASSERT
|
|
|
|
choice ETL_ERROR_MODE
|
|
prompt "ETL error handling mode"
|
|
help
|
|
What ETL does when one of its checks fails.
|
|
|
|
config ETL_ASSERT_ERRORS
|
|
bool "Assert in ETL_DEBUG builds, otherwise ignore"
|
|
help
|
|
With ETL_DEBUG, a failed check calls assert(). Without it, nothing
|
|
is reported, but checks that guard an operation still skip it.
|
|
With ETL_LOG_ERRORS, a failed check calls the error handler instead,
|
|
with or without ETL_DEBUG.
|
|
|
|
config ETL_USE_ASSERT_FUNCTION
|
|
bool "Call a user assert function"
|
|
help
|
|
A failed check calls the function registered with
|
|
etl::set_assert_function(), and checks that guard an operation
|
|
still skip it. Until one is registered, it calls assert(false).
|
|
|
|
config ETL_THROW_EXCEPTIONS
|
|
bool "Throw an exception"
|
|
depends on CPP_EXCEPTIONS
|
|
help
|
|
A failed check throws an etl::exception.
|
|
|
|
config ETL_NO_CHECKS
|
|
bool "No checks"
|
|
help
|
|
Check conditions are not evaluated.
|
|
|
|
endchoice # ETL_ERROR_MODE
|
|
|
|
config ETL_LOG_ERRORS
|
|
bool "Call the ETL error handler"
|
|
depends on !ETL_USE_ASSERT_FUNCTION && !ETL_NO_CHECKS
|
|
help
|
|
A failed check calls the callback registered with
|
|
etl::error_handler::set_callback(). With ETL_THROW_EXCEPTIONS it
|
|
then throws; otherwise, checks that guard an operation still skip
|
|
it. With no callback registered, errors are discarded.
|
|
|
|
choice ETL_ERROR_DETAIL
|
|
prompt "ETL error detail level"
|
|
help
|
|
What information the etl::exception for a failed check carries,
|
|
whether it is thrown or passed to the error handler or assert
|
|
function. Unused when a failed check calls plain assert().
|
|
|
|
config ETL_TERSE_ERRORS
|
|
bool "Short error code only"
|
|
|
|
config ETL_VERBOSE_ERRORS
|
|
bool "Message, file and line"
|
|
|
|
config ETL_MINIMAL_ERRORS
|
|
bool "Nothing"
|
|
|
|
endchoice # ETL_ERROR_DETAIL
|
|
|
|
config ETL_CHECK_PUSH_POP
|
|
bool "Enable push/pop checks in ETL"
|
|
depends on !ETL_NO_CHECKS
|
|
|
|
config ETL_CHECK_INDEX_OPERATOR
|
|
bool "Enable bounds checks on ETL operator[]"
|
|
depends on !ETL_NO_CHECKS
|
|
|
|
config ETL_CHECK_EXTRA
|
|
bool "Enable extra bounds and empty checks in ETL containers"
|
|
depends on !ETL_NO_CHECKS
|
|
|
|
endif # ETL
|