Skip to content

Document optional return types for array pop/shift/at - #34

Draft
ATX24 wants to merge 1 commit into
mainfrom
cursor/skill-md-array-method-types-1f44
Draft

Document optional return types for array pop/shift/at#34
ATX24 wants to merge 1 commit into
mainfrom
cursor/skill-md-array-method-types-1f44

Conversation

@ATX24

@ATX24 ATX24 commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Summary

  • update the Array methods section in plugins/baml/skills/core/SKILL.md
  • annotate optional-returning methods with explicit signatures:
    • pop() -> T?
    • shift() -> T?
    • at(i: int) -> T?
  • clarify null-case behavior for each method
  • add an idiomatic ?? unwrap snippet covering pop/shift/at
  • distinguish void-returning mutators (push, unshift) from optional-returning reads/removals

Validation

  • checked repository layout for build/test configs (no package.json, Makefile, or baml.toml targets present)
  • ran git diff --check (clean)

CodeRabbit

Open in Web Open in Cursor 

Co-authored-by: Dhilan Shah <ATX24@users.noreply.github.com>
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