Skip to content

Prove the native slice IntoBytes implementation - #3894

Open
joshlf wants to merge 1 commit into
Gqvy7wjamomt5ju5ujyh4bgdxfluqkdr3from
G5mwz4ieerzmvrwzsvsuahndzgsjmd53s
Open

joshlf wants to merge 1 commit into
Gqvy7wjamomt5ju5ujyh4bgdxfluqkdr3from
G5mwz4ieerzmvrwzsvsuahndzgsjmd53s

Conversation

@joshlf

@joshlf joshlf commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

Mark the existing unsafe impl for [T] and prove its invariant from the
actual element dictionary and retained model. Initialization covers all
accepted language representations; realizability supplies bytes at each
admitted slice's actual element count.

Preserve native slice identity in trait binding and associated-type
lifting. Reject changed elements and reference lookalikes. Add a Rust
client that exercises slice and unsized-wrapper dictionary selection, and
check its specification against independent count-indexed expectations.
Refresh the complete extraction goldens and annotation snapshots.

Authored by an AI agent acting on joshlf's behalf.


⬇️ Download this PR

Branch

git fetch origin refs/heads/G5mwz4ieerzmvrwzsvsuahndzgsjmd53s && git checkout -b pr-G5mwz4ieerzmvrwzsvsuahndzgsjmd53s FETCH_HEAD

Checkout

git fetch origin refs/heads/G5mwz4ieerzmvrwzsvsuahndzgsjmd53s && git checkout FETCH_HEAD

Cherry Pick

git fetch origin refs/heads/G5mwz4ieerzmvrwzsvsuahndzgsjmd53s && git cherry-pick FETCH_HEAD

Pull

git pull origin refs/heads/G5mwz4ieerzmvrwzsvsuahndzgsjmd53s

Stacked PRs enabled by GHerrit.

Mark the existing unsafe impl for [T] and prove its invariant from the
actual element dictionary and retained model. Initialization covers all
accepted language representations; realizability supplies bytes at each
admitted slice's actual element count.

Preserve native slice identity in trait binding and associated-type
lifting. Reject changed elements and reference lookalikes. Add a Rust
client that exercises slice and unsized-wrapper dictionary selection, and
check its specification against independent count-indexed expectations.
Refresh the complete extraction goldens and annotation snapshots.

gherrit-pr-id: G5mwz4ieerzmvrwzsvsuahndzgsjmd53s
Agent-authored-by: AI agent acting on joshlf's behalf
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T22:23:04.154716Z f3ccf5d PR opened
🔒 Security Review ✅ Completed 2026-10-15T22:24:35.793968Z f3ccf5d PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

This was referenced Oct 15, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request implements and verifies the native slice [T]: IntoBytes implementation in the Aeneas verification framework. It adds the invariant_proof marker to the slice IntoBytes implementation in zerocopy, updates the lowering audit and design documentation, and introduces the corresponding Lean specifications, proofs, and python test cases to verify slice initialization and realizability. I have no feedback to provide.

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 48.62%. Comparing base (158f1d7) to head (f3ccf5d).

Files with missing lines Patch % Lines
zerocopy/src/trait_checks.rs 0.00% 6 Missing ⚠️
Additional details and impacted files
@@                          Coverage Diff                          @@
##           Gqvy7wjamomt5ju5ujyh4bgdxfluqkdr3    #3894      +/-   ##
=====================================================================
- Coverage                              48.67%   48.62%   -0.06%     
=====================================================================
  Files                                     35       35              
  Lines                                   4754     4759       +5     
=====================================================================
  Hits                                    2314     2314              
- Misses                                  2440     2445       +5     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

This branch has not been deployed

No deployments
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.

2 participants