Skip to content

Release cheetah-string v3.0.0 - #136

Merged
mxsm merged 1 commit into
mainfrom
mxsm/cheetah-string-95plus
Jul 26, 2026
Merged

Release cheetah-string v3.0.0#136
mxsm merged 1 commit into
mainfrom
mxsm/cheetah-string-95plus

Conversation

@mxsm

@mxsm mxsm commented Jul 26, 2026

Copy link
Copy Markdown
Owner

Summary

  • Introduce the v3 immutable Inline | Static | Shared representation.
  • Move mutable construction into CheetahBuilder and remove the obsolete CheetahStr facade.
  • Make UTF-8/bytes conversion and typed split semantics explicit.
  • Refresh feature combinations, benchmarks, fuzz targets, examples, and release tooling for v3.
  • Remove obsolete architecture-plan documents and superseded raw evidence artifacts.

Breaking changes

  • CheetahString is now an immutable value type.
  • Mutation belongs to CheetahBuilder or String.
  • The deprecated CheetahStr facade is removed.
  • Split iterator capabilities are expressed by concrete iterator types instead of runtime fallbacks.

Release impact

Cargo.toml is set to 3.0.0. After this PR is merged, the v3.0.0 tag will trigger the repository release workflow to package and publish the crate and create the GitHub Release.

Validation

No additional source changes or duplicate local validation were performed during this publication pass. The tag-triggered release workflow runs formatting, Clippy, feature tests, package creation, crates.io publication, and GitHub Release creation.

Closes #135

Summary by CodeRabbit

  • New Features

    • Released CheetahString v3 with immutable, clone-efficient string storage.
    • Added CheetahBuilder’s finish() workflow and expanded string construction, conversion, querying, transformation, and concatenation APIs.
    • Added explicit split_char and split_str methods with forward-only substring splitting.
    • Added improved bytes-to-string conversion with recoverable UTF-8 errors and copy semantics.
    • Added experimental SIMD support and expanded Serde integration.
  • Breaking Changes

    • CheetahStr is now a deprecated compatibility alias for CheetahString.
    • Older generic split and builder method names are deprecated.

Copilot AI review requested due to automatic review settings July 26, 2026 10:26
@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: b9d43dba-9465-46f3-8885-db7a41489112

📥 Commits

Reviewing files that changed from the base of the PR and between 29315ca and aa3f9f1.

⛔ Files ignored due to path filters (1)
  • fuzz/Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (67)
  • .gitignore
  • Cargo.toml
  • README.md
  • bench-results/README.md
  • bench-results/packed-evidence/20260624-130416/fuzz-packed-from-bytes.txt
  • bench-results/packed-evidence/20260624-130416/fuzz-packed-push-str.txt
  • bench-results/packed-evidence/20260624-130416/packed-asan.txt
  • bench-results/packed-evidence/20260624-130416/packed-bench.txt
  • bench-results/packed-evidence/20260624-130416/packed-miri.txt
  • bench-results/packed-evidence/20260624-130416/packed-test.txt
  • bench-results/packed-evidence/20260624-130416/summary.md
  • benches/comprehensive.rs
  • benches/mq_properties.rs
  • benches/mq_remoting_header.rs
  • benches/mq_topic.rs
  • benches/mutation.rs
  • benches/packed.rs
  • benches/shared_backing.rs
  • benches/simd.rs
  • docs/cheetah-string-architecture-upgrade-plan-95plus.md
  • docs/simd-portability.md
  • examples/comprehensive_patterns.rs
  • examples/test_empty_pattern.rs
  • examples/test_split_behavior.rs
  • fuzz/.gitignore
  • fuzz/Cargo.toml
  • fuzz/fuzz_targets/cheetah_string_transitions.rs
  • fuzz/fuzz_targets/split_differential.rs
  • scripts/audit-rocketmq-usage.ps1
  • scripts/audit-rocketmq-usage.sh
  • scripts/bench-all.ps1
  • scripts/bench-all.sh
  • scripts/bench-frozen-v2.sh
  • scripts/check-msrv-package.sh
  • scripts/compare-benchmarks.ps1
  • scripts/compare-benchmarks.sh
  • scripts/tests/test_verify_score.py
  • scripts/tests/test_workflow_contracts.py
  • scripts/verify-packed.ps1
  • scripts/verify-score.py
  • src/builder.rs
  • src/bytes.rs
  • src/cheetah_str.rs
  • src/cheetah_string.rs
  • src/cheetah_string/construct.rs
  • src/cheetah_string/convert.rs
  • src/cheetah_string/pattern.rs
  • src/cheetah_string/query.rs
  • src/cheetah_string/repr.rs
  • src/cheetah_string/traits.rs
  • src/inline.rs
  • src/lib.rs
  • src/serde.rs
  • src/simd.rs
  • src/unsafe_proof.md
  • tests/allocation_contract.rs
  • tests/api_extensions.rs
  • tests/basic.rs
  • tests/bytes.rs
  • tests/comprehensive_tests.rs
  • tests/layout_snapshot.rs
  • tests/mutation.rs
  • tests/patterns.rs
  • tests/serde.rs
  • tests/simd.rs
  • tests/split_edge_cases.rs
  • tests/type_split.rs

📝 Walkthrough

Walkthrough

CheetahString v3 replaces mutable and legacy string surfaces with immutable inline/static/shared storage, CheetahBuilder mutation, typed splitting, richer bytes errors, updated SIMD features, benchmark evidence tooling, fuzz targets, and fail-closed release verification.

Changes

CheetahString v3 API and storage

Layer / File(s) Summary
Immutable storage and public API
src/cheetah_string/*, src/lib.rs, src/builder.rs, src/cheetah_string/repr.rs
CheetahString now uses inline, static, or shared storage; CheetahStr becomes a deprecated alias; builder freezing uses finish().
Typed splitting and queries
src/cheetah_string/pattern.rs, src/cheetah_string/query.rs, tests/split_edge_cases.rs, examples/*split*
Character and substring splitting use separate APIs, with forward-only string-pattern iteration and expanded query/transformation methods.
Bytes and serialization
src/bytes.rs, src/serde.rs, tests/bytes.rs, tests/serde.rs
Bytes conversions add copy boundaries and FromUtf8BytesError; Serde support targets CheetahString.
Contracts and compatibility tests
tests/allocation_contract.rs, tests/layout_snapshot.rs, tests/mutation.rs, tests/type_split.rs
Allocation, layout, clone-sharing, builder, and deprecated compatibility behavior receive explicit tests.

Benchmark and release evidence

Layer / File(s) Summary
Benchmark coverage
benches/*, Cargo.toml
Benchmarks use batched Criterion measurements, add shared-backing and builder workloads, and use deterministic SIMD inputs.
Capture and comparison harnesses
scripts/bench-all.*, scripts/bench-frozen-v2.sh, scripts/compare-benchmarks.*, scripts/check-msrv-package.sh
Capture scripts record provenance and contracts; comparison scripts calculate performance gates and invoke score verification.
Release verification
scripts/verify-score.py, scripts/tests/test_verify_score.py, scripts/tests/test_workflow_contracts.py
Release evidence is validated through locked manifests, immutable artifacts, attestations, downstream metrics, and fail-closed tests.
Fuzzing and packed validation
fuzz/*, scripts/verify-packed.ps1
New transition and split differential fuzz targets are feature-gated, and packed Miri, ASan, and fuzz commands use explicit feature and argument wiring.

Estimated code review effort: 5 (Critical) | ~120 minutes

Possibly related PRs

Suggested reviewers: copilot, teslarustor

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch mxsm/cheetah-string-95plus

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@mxsm
mxsm merged commit 84c8d84 into main Jul 26, 2026
7 of 8 checks passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Releases cheetah-string v3.0.0 by completing the migration to an immutable, clone-cheap CheetahString (Inline | Static | Shared), pushing mutation into CheetahBuilder, and making split + bytes/UTF-8 conversion semantics explicit while refreshing tests, benchmarks, fuzz targets, and release tooling.

Changes:

  • Finalize the v3 immutable CheetahString core, typed split APIs (split_char / split_str), and explicit bytes/UTF-8 conversion/error surfaces.
  • Update tests/benches/examples/fuzzing/scripts to reflect the v3 contracts, including allocation/layout evidence capture tooling.
  • Remove superseded docs/artifacts and refresh release/feature wiring (e.g., experimental-simd + deprecated simd alias).

Reviewed changes

Copilot reviewed 65 out of 68 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
Cargo.toml Bumps crate to 3.0.0, updates description/excludes, and formalizes experimental-simd + deprecated simd alias.
.gitignore Ignores regenerable benchmark/evidence outputs while keeping human summaries.
src/lib.rs Updates crate docs and public exports for v3 (immutable core, builder guidance, split capability, bytes error type).
src/builder.rs Moves to finish() as canonical freeze API; keeps deprecated finish_string() for compatibility.
src/bytes.rs Adds FromUtf8BytesError preserving the original bytes::Bytes buffer; updates conversion APIs.
src/inline.rs Removes inline mutation helper consistent with immutability shift.
src/simd.rs Renames feature gate to experimental-simd and tightens unsafe documentation/blocks under deny(unsafe_op_in_unsafe_fn).
src/serde.rs Removes CheetahStr serde support and keeps CheetahString serialization contract.
src/unsafe_proof.md Reframes packed prototype doc as a safety analysis with strict-provenance caveats.
src/cheetah_string/repr.rs Removes mutable/owned representation variant so v3 is Inline/Static/Shared only.
src/cheetah_string/construct.rs New: v3 constructors and safe/unsafe UTF-8 entry points with explicit policies.
src/cheetah_string/convert.rs New: From/TryFrom/Deref/iterator conversions aligned with immutable value semantics.
src/cheetah_string/query.rs New: query/split APIs with typed iterator capability (split_char, forward-only split_str, deprecated v2 split).
src/cheetah_string/pattern.rs Refactors split pattern handling to return capability-preserving iterator types (no runtime panic).
src/cheetah_string/traits.rs New: core trait impls (Eq/Ord/Hash/Display/Debug/Add/PartialEq), optionally using experimental SIMD.
src/cheetah_str.rs Deletes obsolete CheetahStr implementation (replaced by deprecated alias to CheetahString).
tests/type_split.rs Updates split/type tests to v3 APIs and adds compatibility assertions for deprecated aliases.
tests/split_edge_cases.rs Converts to typed split APIs and aligns behavior with stdlib, removing old reverse-iteration panic expectation.
tests/patterns.rs Updates pattern tests to split_char/split_str.
tests/comprehensive_tests.rs Updates iterator behavior tests for typed split; removes old panic-based reverse tests for string patterns.
tests/mutation.rs Replaces mutable CheetahString mutation tests with CheetahBuilder + immutable concatenation contracts.
tests/basic.rs Updates into<String> expectations for frozen/shared payload behavior under v3.
tests/bytes.rs Adds coverage for FromUtf8BytesError buffer preservation and explicit copy boundaries.
tests/serde.rs Migrates serde tests from CheetahStr to CheetahString.
tests/simd.rs Replaces feature-gated SIMD-only tests with deterministic semantic boundary tests.
tests/layout_snapshot.rs Tightens layout contract assertions by pointer width (exact size/align expectations).
tests/allocation_contract.rs New: allocation-counting global allocator test establishing v3 clone/allocation contracts.
examples/test_split_behavior.rs Updates example to typed split APIs.
examples/test_empty_pattern.rs Updates example to split_str("").
examples/comprehensive_patterns.rs Updates example output and calls to typed split APIs.
benches/comprehensive.rs Updates benchmarks for v3 builder/immutability patterns and improves Criterion batching correctness.
benches/mutation.rs Reorients benchmarks around CheetahBuilder and immutable Add behavior; adds freeze/into_string benches.
benches/simd.rs Adds backend labeling + deterministic data generation for equality/prefix/suffix/search benchmarks.
benches/mq_topic.rs Improves batching; corrects throughput accounting for lookup benches.
benches/mq_properties.rs Improves batching and black_box usage for fairer property benchmarks.
benches/mq_remoting_header.rs Improves batching and black_box usage for fairer header encode/parse benches.
benches/packed.rs Updates packed benches to use CheetahBuilder for mutation paths.
fuzz/Cargo.toml Splits packed fuzzing behind a feature; adds new fuzz targets for split + representation transitions.
fuzz/Cargo.lock Updates lock to v3 alpha dependency graph used by fuzz harness.
fuzz/.gitignore Ignores fuzz artifacts/corpus/coverage/target.
fuzz/fuzz_targets/split_differential.rs New: differential fuzzing for split_char/split_str vs stdlib.
fuzz/fuzz_targets/cheetah_string_transitions.rs New: fuzzing transitions between borrowed/owned/builder/concat behaviors.
scripts/bench-all.sh Rewrites benchmark capture script with schema/metadata/contracts and deterministic capture flow.
scripts/bench-all.ps1 PowerShell benchmark capture parity with the bash script.
scripts/bench-frozen-v2.sh New: frozen v2 baseline capture harness for comparative gates.
scripts/compare-benchmarks.sh New: compares base/head Criterion evidence against gate manifest and emits verified score ledger.
scripts/check-msrv-package.sh New: validates MSRV consumer builds against the packaged crate.
scripts/verify-packed.ps1 Updates packed gates: strict-provenance Miri, isolated packed test target, and fuzz feature wiring.
scripts/audit-rocketmq-usage.sh New: inventories downstream RocketMQ usage patterns for migration/compat tracking.
scripts/audit-rocketmq-usage.ps1 New: PowerShell equivalent of downstream usage inventory.
docs/simd-portability.md Removes obsolete SIMD portability doc (content appears superseded by new policy/docs references).
bench-results/README.md Removes obsolete benchmark artifact layout documentation.
bench-results/packed-evidence/20260624-130416/summary.md Removes superseded raw packed evidence capture summary.
bench-results/packed-evidence/20260624-130416/packed-test.txt Removes superseded raw packed test log artifact.
bench-results/packed-evidence/20260624-130416/packed-miri.txt Removes superseded raw packed Miri log artifact.
bench-results/packed-evidence/20260624-130416/packed-asan.txt Removes superseded raw packed ASan log artifact.
bench-results/packed-evidence/20260624-130416/fuzz-packed-from-bytes.txt Removes superseded raw packed fuzz log artifact.
bench-results/packed-evidence/20260624-130416/fuzz-packed-push-str.txt Removes superseded raw packed fuzz log artifact.
bench-results/packed-evidence/20260624-130416/packed-bench.txt Removes superseded raw packed benchmark log artifact.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/lib.rs
Comment on lines +43 to 46
//! ```toml
//! [dependencies]
//! cheetah-string = { version = "=3.0.0-alpha.1", features = ["experimental-simd"] }
//! ```
Comment thread src/unsafe_proof.md
Comment on lines +46 to +51
This is not a completed safety proof. Strict-provenance Miri rejects the
integer-to-pointer reconstruction used by the heap representation. The
prototype is intentionally not wired into stable `CheetahString`; it remains a
contained negative experiment until a preserving-provenance redesign satisfies
every gate above. See ADR 006 and the local safety summary for the recorded
decision and diagnostic evidence.
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.

Release cheetah-string v3.0.0

2 participants