Skip to content

docs: rewrite README and fix requirements in docs/index.md - #75

Closed
biobo-bot[bot] wants to merge 1 commit into
mainfrom
docs/readme-rewrite
Closed

biobo-bot[bot] wants to merge 1 commit into
mainfrom
docs/readme-rewrite

Conversation

@biobo-bot

@biobo-bot biobo-bot Bot commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

Summary

Rewrite README.md so it reflects the v0.9.5 API and the build/packaging
setup that actually exists, and fix the requirements listed in
docs/index.md.

Changes

  • README hero: a short std::variant<int, std::string> match that shows a
    literal case, bindings whose values the handlers use, guards that pick
    the branch, and the _ fallback.
  • README Quick Tour restructured: literals and value guards, structs,
    structured-binding placeholders, std::variant (is<T> / alt<I>),
    combinators, an event-dispatch example, and cached case packs.
  • New Core Concepts table summarizing the public API.
  • New Requirements section taken from cmake/CheckCompilerVersion.cmake
    (GCC 11, Clang 12, AppleClang 14, MSVC 19.30, clang-cl 18) plus the
    compilers and standards covered by CI.
  • Installation: vcpkg, FetchContent (v0.9.5), install + find_package,
    and subdirectory / include-path options.
  • Building the Tests lists the PTN_* CMake options; adds a License
    section and links to AGENTS.md and SECURITY.md.
  • docs/index.md: correct the MSVC minimum (19.30 / VS2022, not 2019),
    list the CMake-checked minimums, and drop the macOS claim (AppleClang 14
    is accepted by the CMake check but not tested in CI).

Testing

  • Compiled every C++ snippet in the new README with Clang in C++17 and
    C++20 using -Wall -Wextra -Werror, with asserts on the results; all
    passed.
  • Built and ran ptn_tests locally on this branch's base: all tests
    passed (the separate C++20 member-names target was not built).

@biobo-bot biobo-bot Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the README rewrite and the docs/index.md requirements fix. This looks good to me, and I have no blocking issues.

What I checked:

  • The Requirements tables match cmake/CheckCompilerVersion.cmake (GCC 11, Clang 12, AppleClang 14, MSVC 19.30, clang-cl 18 with an MSVC 19.30+ toolset). Correcting MSVC from "2019" to 19.30 / VS2022 is the right fix.
  • The PTN_* options listed under Building the Tests match CMakeLists.txt, and the "on by default only when top-level" note matches PTN_MASTER_PROJECT.
  • The FetchContent tag is v0.9.5, and the install + find_package flow turns off tests, benchmarks, and samples, which is sensible for an install-only build.
  • The hero and Quick Tour examples use bindings whose values are actually consumed by the handlers, and the guards pick branches as intended. The note that >> binds tighter than || / && is correct C++ precedence.
  • The PTN_ON scoping note keeps the important caveat from the old README (captureless lambda, so use namespace scope, C++20 static, or PTN_BIND in C++17) in a shorter form.
  • CI on this head is green apart from a couple of jobs still running.

Two optional nits:

  • The Performance Tuning link goes to GitHub while the other docs links go to patternia.tech. That's fine, since guide/performance-tuning.md isn't in the mkdocs.yml nav yet. If it gets added later, this link could switch over.
  • PTN_DEV_INDEX isn't in the options list. That seems intentional, since it's an IDE-only target.

I'm leaving this as a comment rather than an approval because GitHub doesn't let a PR's author (Biobo Bot) approve its own pull request, so a maintainer needs to approve it.

@sentomk sentomk closed this Oct 30, 2026
@biobo-bot
biobo-bot Bot deleted the docs/readme-rewrite branch October 30, 2026 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant