smithery.ai

cairo-operator-overloading

Explain Cairo operator overloading using core::ops traits like Add; use when a request involves redefining operators for custom types in Cairo.

First seen May 1, 2026

Installation

$ npx skills add https://smithery.ai

Also in this package

Other skills from smithery.ai · top by installs.

npx skills add https://smithery.ai

Browse all from smithery.ai

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 929 B
  • docs SUMMARY.md 177 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 1 installs

SKILL.md

Cairo Operator Overloading

Overview

Show how to overload operators by implementing the corresponding trait.

Quick Use

  • Read references/operator-overloading.md before answering.
  • Use a concise example like impl TypeAdd of Add<Type>.
  • Emphasize that operator meaning should remain intuitive.

Response Checklist

  • Choose the correct trait (e.g., Add, Sub, Mul, Div, Rem, Neg).
  • Implement the trait for the concrete RHS type (Add<Other> or Add<Self>).
  • Return a new value with the expected semantics.

Example Requests

  • "How do I implement + for a custom struct?"
  • "Can I overload operators in Cairo?"

Cairo by Example