Skip to content

Один LruCache вместо двух - #1756

Merged
EvilBeaver merged 1 commit into
EvilBeaver:developfrom
sfaqer:refactor/single-lru-cache
Sep 27, 2026
Merged

EvilBeaver merged 1 commit into
EvilBeaver:developfrom
sfaqer:refactor/single-lru-cache

Conversation

@sfaqer

@sfaqer sfaqer commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

По замечанию в #1755: ScriptEngine.Machine.LruCache повторял OneScript.Commons.LruCache (появился позже, для кэша Выполнить/Вычислить) и использовался только в MachineInstance. Копию удалил, MachineInstance берет кэш из Commons.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Removed
    • Least-recently-used cache functionality is no longer available. Existing integrations that rely on this cache may need an alternative.

Копия в ScriptEngine.Machine повторяла OneScript.Commons.LruCache и
использовалась только в MachineInstance. Теперь там кэш из Commons.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 42a8d394-c8ad-41fb-a58b-7420a0c05ff6

📥 Commits

Reviewing files that changed from the base of the PR and between 38953db and 56f6497.

📒 Files selected for processing (1)
  • src/ScriptEngine/Machine/LruCache.cs
💤 Files with no reviewable changes (1)
  • src/ScriptEngine/Machine/LruCache.cs

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.


📝 Walkthrough

Walkthrough

The public LruCache<TKey, TValue> class was removed, including its constructor, cache operations, and dictionary and linked-list implementation.

Changes

Cache API removal

Layer / File(s) Summary
Remove LruCache
src/ScriptEngine/Machine/LruCache.cs
The class, constructor, IsEmpty, Clear, and GetOrAdd were removed, along with the storage and least-recently-used ordering logic.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Refactor

Merge Risk: ⚪ Minimal · up to 56f64

No repository caller needs a migration, and no actionable incompatibility was established. The change is mergeable after normal checks.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: removing the duplicate ScriptEngine.Machine.LruCache and using one shared LruCache implementation instead.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR

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.

@EvilBeaver
EvilBeaver merged commit fa06f0f into EvilBeaver:develop Sep 27, 2026
1 of 2 checks passed
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