Parser Developer

Enforce token-position conventions and debugging tools for AILANG parser development.

33|5|Updated Sep 26, 2025
One-click install
npx skills add https://github.com/sunholo-data/ailang --skill parser-developer
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Parser Developer
Source: https://github.com/sunholo-data/ailang/tree/main/.claude/skills/parser-developer
Command: npx skills add https://github.com/sunholo-data/ailang --skill parser-developer

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill eliminates token position bugs and development time sinks by providing critical parser conventions and debugging tools for AILANG.

Core Features & Use Cases

  • Token Position Management: Enforces the critical convention that parser functions leave cursor AT the last token, not after it.
  • Debugging Tools: Provides token tracing and API discovery scripts to accelerate development.
  • Use Case: When modifying the AILANG parser or debugging parsing issues, use this Skill to understand proper token positioning and avoid common pitfalls that waste development time.

Quick Start

Use the Parser Developer skill to understand how to properly handle token positioning when writing new parser functions for AILANG.

Frequently Asked Questions about Parser Developer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix token position bugs in AILANG parser development?

Token position bugs occur when parser functions leave the cursor after the last token instead of at it. Parser Developer enforces the convention that cursor position must stay at the last token, not advance beyond it, preventing common debugging pitfalls that waste development time.

What conventions should I follow when writing AILANG parser functions?

AILANG parser functions must leave the cursor at the last token, not after it. The lexer never generates NEWLINE tokens, and parser architecture relies on this positioning contract. Parser Developer documents these critical conventions to prevent bugs when modifying or extending the parser.

How do I debug AILANG parser issues with token tracing?

Enable token tracing by setting DEBUG_PARSER=1 to trace token flow and identify positioning errors. Parser Developer provides this debugging tool alongside token-position validation to accelerate development and help you understand parser behavior during syntax modifications or bug fixes.

How can I discover the parser API when adding new AILANG syntax?

Run 'make doc PKG=<package>' to enable API discovery for the parser module. Parser Developer documents this command alongside token conventions so you can understand existing parser functions and their signatures before adding new syntax extensions.

What's the difference between leaving the cursor at the last token versus after it in parsers?

Leaving the cursor at the last token allows subsequent parser calls to access and validate that token; positioning after it skips validation and causes state misalignment. Parser Developer clarifies this distinction and the architectural reasons AILANG requires the at-token convention to function correctly.

Do I need to understand AST structure before using this parser debugging Skill?

Parser Developer targets parser development and debugging specifically, not AST traversal. While familiarity with parsing concepts helps, the Skill focuses on token positioning rules and debugging tools; you should understand basic parser conventions but the Skill teaches AILANG-specific practices.