Verified Rust for low-level systems code
This report presents the forensic synthetic code analysis of verus-lang/verus, a Rust project with 2,722 GitHub stars. SynthScan v2.0 examined 507,368 lines of code across 1278 source files, recording 1081 pattern matches distributed across 11 syntactic categories. The overall adjusted score of 2.7 places this repository in the Likely human-written band.
The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).
Longitudinal tracking requires multiple scan runs. Once this repository is re-scanned after new commits land, this chart will visualise how the synthetic code signal evolves over time — enabling you to detect whether AI authorship is growing, stabilising, or being actively corrected by human engineers.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 1081 distinct pattern matches across 11 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tools/vargo/src/util.rs | 1 | // Some of the code in this file is copied from https://github.com/rust-lang/cargo/blob/cee088b0db01076deb11c037fe8b64b2 | COMMENT |
| LOW | tools/verita/src/main.rs | 21 | /// Base of the Verus repository | COMMENT |
| LOW | source/Cargo.toml | 41 | # correctness/perf/suspicious are the priority groups | COMMENT |
| LOW | source/verusdoc/src/main.rs | 61 | COMMENT | |
| LOW | source/verusdoc/src/main.rs | 81 | // </div> | COMMENT |
| LOW | source/tools/coverage.sh | 1 | #!/usr/bin/env bash | COMMENT |
| LOW | source/tools/bump_crate_versions/src/main.rs | 21 | /// is modified, we also update the version in the cargo-verus template. The code is optimized | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 1 | use super::layout::*; | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 21 | /// to and from the `usize` address. What _really_ matters is the type paramter of the | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 41 | /// * [`MemContents::Init(v)`](raw_ptr::MemContents::Init) if the memory points-to the | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 61 | /// // ALLOCATE | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 81 | /// | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 101 | /// | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 121 | /// // ALLOCATE p | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 141 | /// * Since `PPtr` is just a pointer (represented by an integer), it can be `Copy`. | COMMENT |
| LOW | source/vstd/simple_pptr.rs | 181 | /// Cast a pointer to an integer. | COMMENT |
| LOW | source/vstd/pervasive.rs | 61 | spec fn ghost_ensures(&self) -> bool; | COMMENT |
| LOW | source/vstd/pervasive.rs | 161 | /// if (a >= 50) { | COMMENT |
| LOW | source/vstd/pervasive.rs | 221 | /// `assert_by_contradiction!(b, { /* proof */ });` | COMMENT |
| LOW | source/vstd/pervasive.rs | 261 | /// level, while `K` allows the user to configure the invariant upon construction. | COMMENT |
| LOW | source/vstd/pervasive.rs | 281 | /// | COMMENT |
| LOW | source/vstd/pervasive.rs | 301 | /// The user can also provide boolean predicate declarations, which are copied verbatim | COMMENT |
| LOW | source/vstd/pervasive.rs | 321 | /// | COMMENT |
| LOW | source/vstd/pervasive.rs | 341 | /// The graph of dependencies across all fields must be acyclic. | COMMENT |
| LOW | source/vstd/pervasive.rs | 361 | /// | COMMENT |
| LOW | source/vstd/tokens.rs | 21 | }; | COMMENT |
| LOW | source/vstd/tokens.rs | 61 | /// Though the first argument is mutable, the value is not really mutated; | COMMENT |
| LOW | source/vstd/tokens.rs | 101 | COMMENT | |
| LOW | source/vstd/tokens.rs | 181 | /// | VerusSync Strategy | Field type | Token trait | | COMMENT |
| LOW | source/vstd/tokens.rs | 221 | /// Interface for VerusSync tokens created for a field marked with the `bool` or | COMMENT |
| LOW | source/vstd/layout.rs | 21 | COMMENT | |
| LOW | source/vstd/layout.rs | 121 | size_of::<V>() as usize as nat == size_of::<V>(), | COMMENT |
| LOW | source/vstd/utf8.rs | 1 | //! Definitions for UTF-8 encoding and decoding of character sequences. | COMMENT |
| LOW | source/vstd/iset_lib.rs | 41 | /// we can write either `s.map(|i: int| (i, 10 * i))` | COMMENT |
| LOW | source/vstd/iset_lib.rs | 1461 | } | COMMENT |
| LOW | source/vstd/cell.rs | 21 | COMMENT | |
| LOW | source/vstd/cell.rs | 41 | /// | COMMENT |
| LOW | source/vstd/set_lib.rs | 41 | /// such that `rev(fwd(a)) == a`. | COMMENT |
| LOW | source/vstd/set_lib.rs | 1361 | /// assert_sets_equal!(set1 == set2); | COMMENT |
| LOW | source/vstd/thread.rs | 61 | /// | COMMENT |
| LOW | source/vstd/thread.rs | 81 | /// | COMMENT |
| LOW | source/vstd/vstd.rs | 1 | //! The "standard library" for [Verus](https://github.com/verus-lang/verus). | COMMENT |
| LOW | source/vstd/vstd.rs | 141 | std_specs::vecdeque::group_vec_dequeue_axioms, | COMMENT |
| LOW | source/vstd/atomic_ghost.rs | 221 | /// [`AtomicI64`], [`AtomicI32`], [`AtomicI16`], [`AtomicI8`], and [`AtomicBool`]. | COMMENT |
| LOW | source/vstd/atomic_ghost.rs | 241 | /// Here, the `$operation_name` is one of `load`, `store`, etc. Meanwhile, | COMMENT |
| LOW | source/vstd/atomic_ghost.rs | 261 | /// | `compare_exchange_weak(x, y)` | `prev == x && next == y && ret == Ok(prev)` ("success") OR<br> `next == prev && re | COMMENT |
| LOW | source/vstd/atomic_ghost.rs | 281 | /// | COMMENT |
| LOW | source/vstd/atomic_ghost.rs | 301 | /// let result = atomic_with_ghost!( | COMMENT |
| LOW | source/vstd/imap.rs | 1 | #![allow(unused_imports)] | COMMENT |
| LOW | source/vstd/imap.rs | 21 | /// * [`IMap::empty()`] constructs an empty map. | COMMENT |
| LOW | source/vstd/imap.rs | 381 | /// | COMMENT |
| LOW | source/vstd/imap.rs | 401 | /// | COMMENT |
| LOW | source/vstd/seq.rs | 121 | } | COMMENT |
| LOW | source/vstd/seq.rs | 201 | /// ```rust | COMMENT |
| LOW | source/vstd/seq.rs | 221 | /// } | COMMENT |
| LOW | source/vstd/seq.rs | 261 | self.subrange(n, self.len() as int) | COMMENT |
| LOW | source/vstd/function.rs | 1 | use super::prelude::*; | COMMENT |
| LOW | source/vstd/multiset.rs | 21 | /// | COMMENT |
| LOW | source/vstd/multiset.rs | 41 | // (1) representing multiplicity by an ordinal or cardinal or something | COMMENT |
| LOW | source/vstd/multiset.rs | 81 | /// the resulting multiset is the sum of its multiplicities in the operands. | COMMENT |
| 921 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | source/vir/src/sst_to_air.rs | 2103 | .map(|fun| fun.x.ret.x.typ.clone()); | CODE |
| CRITICAL | source/vir/src/ast_simplify.rs | 1085 | typ: function.x.ret.x.typ.clone(), | CODE |
| CRITICAL | source/vir/src/ast_simplify.rs | 1109 | name: function.x.ret.x.name.clone(), | CODE |
| CRITICAL | source/vir/src/ast_simplify.rs | 1110 | a: function.x.ret.x.typ.clone(), | CODE |
| CRITICAL | source/vir/src/headers.rs | 556 | let mut name = method.x.name.path.segments.last().expect("method name last").to_string(); | CODE |
| CRITICAL | source/vir/src/headers.rs | 565 | let name = method.x.name.path.segments.last().expect("method name last").to_string(); | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 278 | function.x.ret.x.typ.clone(), | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 329 | function.x.ret.x.typ.clone(), | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 373 | name: function.x.ret.x.name.clone(), | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 375 | typ: function.x.ret.x.typ.clone(), | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 678 | .insert(trait_function.x.ret.x.name.clone(), function.x.ret.x.name.clone()); | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 934 | let non_default_ensure = &lo_inheritance.function.x.ensure.0.clone(); | CODE |
| CRITICAL | source/vir/src/ast_to_sst_func.rs | 948 | for expr in lo_current.function.x.ensure.0.iter().chain(lo_current.function.x.ensure.1.iter()) { | CODE |
| CRITICAL | source/state_machines_macros/src/lemmas.rs | 110 | if l.func.sig.generics.params.len() > 0 { | CODE |
| CRITICAL | source/rustc_mir_build/src/builder/mod.rs | 272 | let ids = (id.0.owner.def_id.local_def_index.as_usize(), id.0.local_id); | CODE |
| CRITICAL | source/rustc_mir_build/src/builder/mod.rs | 277 | dbg!(real_id.0.owner.def_id.local_def_index.as_usize()); | CODE |
| CRITICAL | …build_additional_files/verus_time_travel_prevention.rs | 1202 | let v_id = v.0.owner.def_id.local_def_index.as_usize(); | CODE |
| CRITICAL | …build_additional_files/verus_time_travel_prevention.rs | 1214 | let v_id = v.0.owner.def_id.local_def_index.as_usize(); | CODE |
| CRITICAL | …build_additional_files/verus_time_travel_prevention.rs | 1233 | v.0.owner.def_id.local_def_index.as_usize() + mod_idx, | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tools/verita/scripts/summarize.py | 124 | # ── Single-run output ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/scripts/summarize.py | 195 | # ── Single-run Markdown output ──────────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/scripts/summarize.py | 250 | # ── Error summary (Markdown only) ───────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/scripts/summarize.py | 295 | # ── Two-run comparison output ────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/scripts/summarize.py | 500 | # ── Two-run comparison Markdown output ──────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/scripts/summarize.py | 619 | # ── Main ─────────────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/src/dependencies.rs | 99 | // ── String form ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tools/verita/src/dependencies.rs | 112 | // ── Table form ─────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | source/docs/guide/custom-admonitions.py | 9 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/custom-admonitions.py | 11 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 67 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 69 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 188 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 190 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 299 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | source/docs/guide/verus-grammar.py | 301 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 111 | // ┌─────────────────────────────────┐ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 114 | // │ ┌───────────────────────────┐ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 116 | // │ └───────────────────────────┘ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 117 | // │ ┌───────────────────────────┐ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 120 | // │ │ ┌─────────────────────┐ │ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 122 | // │ │ └─────────────────────┘ │ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 126 | // │ │ ┌─────────────────────┐ │ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 128 | // │ │ └─────────────────────┘ │ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 129 | // │ └───────────────────────────┘ │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 130 | // └─────────────────────────────────┘ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 134 | // ┌────────▼───────┐ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 136 | // └────────┬───────┘ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 137 | // │ ┌────────────────┐ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 138 | // ┌────────▼───────┐ │Drop temporaries│ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 139 | // │Test the pattern├──────►in y() │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 140 | // └────────┬───────┘ │because breaking│ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 142 | // ┌────────▼───────┐ │scope │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 143 | // │Move value into │ └───────┬────────┘ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 145 | // └────────┬───────┘ ┌───────▼────────┐ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 147 | // ┌────────▼───────┐ │temporaries in │ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 151 | // │out of <expr> │ └───────┬────────┘ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 153 | // └────────┬───────┘ ┌───────▼────────┐ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 154 | // │ │Enter <else> ├────────► | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 155 | // ┌────────▼───────┐ │block │ return; | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 156 | // │Continue... │ └────────────────┘ | COMMENT |
| MEDIUM⚡ | source/rustc_mir_build/src/builder/block.rs | 157 | // └────────────────┘ | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | source/vstd/arithmetic/internals/mod_internals.rs | 306 | /// and `r == x % n`. Essentially, this is the converse of the | COMMENT |
| MEDIUM | source/builtin_macros/src/attr_rewrite.rs | 1152 | // function body, to enable seamless use of unverified call to the function in | COMMENT |
| MEDIUM | source/builtin_macros/src/lib.rs | 591 | /// Below is a non-exhaustive list of supported spec expressions. Items marked with a \* utilize unverified translations | COMMENT |
| MEDIUM | source/rust_verify_test/tests/bitvector.rs | 202 | ensures(forall |i: u64| (1u64 << i) > 0); // Although this line should be reported instead of the above line | CODE |
| MEDIUM | source/vir/src/resolution_types.rs | 76 | /// Definitely has no resolvedness, no need to recurse (e.g., &T) | COMMENT |
| MEDIUM | source/vir/src/well_formed.rs | 797 | // REVIEW: not robust to normalization | COMMENT |
| MEDIUM | source/vir/src/interpreter.rs | 715 | // TODO: Make the matching here more robust to changes in vstd | COMMENT |
| MEDIUM | source/vir/src/interpreter.rs | 807 | // TODO: Make the matching here more robust to changes in vstd | COMMENT |
| MEDIUM | source/vir/src/interpreter.rs | 841 | // TODO: More robust way of pointing to vstd's sequence functions | COMMENT |
| MEDIUM | source/state_machines_macros/src/simplify_asserts.rs | 8 | /// Essentially, we replace | COMMENT |
| MEDIUM | source/rustc_mir_build/src/thir/pattern/check_match.rs | 308 | // Essentially a field access. | COMMENT |
| MEDIUM | examples/guide/higher_order_fns.rs | 183 | // Inside the closure, we have seamless access to | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | BUILD.md | 18 | ## Step 1: Setup Z3 | COMMENT |
| LOW | BUILD.md | 35 | ## Step 2: Ensure you have a recent rustup installed | COMMENT |
| LOW | BUILD.md | 41 | ## Step 3: Build Verus | COMMENT |
| LOW | source/state_machines_macros/src/simplification.rs | 180 | // Step 1: Collect any field which is newly updated in any branch. | COMMENT |
| LOW | source/state_machines_macros/src/simplification.rs | 192 | // Step 2: For each field and each branch, check if it needs to be | COMMENT |
| LOW | source/rustc_mir_build_additional_files/verus.rs | 1208 | // Step 1: Get the Verus capture set | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | source/rust_verify_test/tests/fndef_types.rs | 999 | // Example usage | COMMENT |
| LOW | source/rust_verify_test/tests/fndef_types.rs | 1079 | // Example usage | COMMENT |
| LOW | examples/statics.rs | 150 | // Example usage | COMMENT |
| LOW | examples/state_machines/tutorial/unverified_rc.rs | 61 | // Example usage | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | source/state_machines_macros/src/simplification.rs | 180 | // Step 1: Collect any field which is newly updated in any branch. | COMMENT |
| LOW | source/state_machines_macros/src/simplification.rs | 192 | // Step 2: For each field and each branch, check if it needs to be | COMMENT |
| LOW | source/rust_verify/src/external.rs | 645 | /// So when we come across an autoderive struct, we need to check if | COMMENT |
| LOW | source/rustc_mir_build_additional_files/verus.rs | 1208 | // Step 1: Get the Verus capture set | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tools/verita/scripts/summarize.py | 10 | CODE | |
| LOW | source/docs/guide/custom-admonitions.py | 22 | CODE | |
| LOW | source/docs/guide/verus-grammar.py | 71 | CODE | |
| LOW | source/docs/guide/verus-grammar.py | 203 | CODE | |
| LOW | source/docs/guide/verus-grammar.py | 78 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | source/vstd/map.rs | 50 | dummy_key: core::marker::PhantomData<K>, | CODE |
| LOW | source/vstd/map.rs | 51 | dummy_value: core::marker::PhantomData<V>, | CODE |
| LOW | source/rustc_mir_build/src/builder/scope.rs | 299 | let fake_data = | CODE |
| LOW | source/rustc_mir_build/src/builder/scope.rs | 301 | let drop_nodes = IndexVec::from_raw(vec![DropNode { data: fake_data, next: DropIdx::MAX }]); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | source/builtin_macros/src/contrib/exec_spec.rs | 164 | // TODO: implement ExecSpecType for Option<T> so that | COMMENT |
| LOW | source/builtin/src/lib.rs | 642 | // TODO: implement this (using unsafe) or mark function as ghost (if supported by Rust) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tools/verita/scripts/summarize.py | 502 | def print_comparison_summary_md(old_results, new_results): | CODE |
| LOW | tools/verita/scripts/analyze.py | 75 | def read_json_files_into_projects(directory): | CODE |