Skip to content

Unicode Gauntlet legality table lists Dart as a Unicode-identifier language; Dart identifiers are ASCII-only #3954

Closed

Description

@squid-protocol

Found by the GitGalaxy-vs-tree-sitter comparison (PR #3953).

tests/unicode_gauntlet/legality.json puts dart in the unicode rule, so the gauntlet renames Dart functions to नाम, 変数 and so on. But the Dart language spec allows only ASCII in identifiers: IDENTIFIER_START: LETTER | '_' | '$', where LETTER is 'a'..'z' | 'A'..'Z'. Those cells therefore test code that isn't valid Dart. tree-sitter-dart rightly refuses them (3/102 before the comparison excluded them as not-legal).

Fix:

  • Move dart out of the unicode rule, so it gets only the ASCII-name encoding cells, like other ASCII-only languages.
  • Decide whether #3814 (part 5): UAX #31 names for Rust, Swift, Dart, PHP and Ruby #3877's Dart name patterns (UAX chore(deps): bump urllib3 from 2.6.3 to 2.7.0 in /gitgalaxy #31) should go back to ASCII. Accepting non-ASCII names is lenient rather than harmful: it could only misread invalid Dart. But the legality table and the patterns should agree.
  • Audit the rest of the table against each spec while there. For example, Kotlin identifiers take Unicode letters and digits but no combining marks (Mn/Mc) outside backticks, so its Devanagari / Tamil / NFD cells may also be testing illegal code.

🤖 Generated with Claude Code

https://claude.ai/code/session_01TmgE1CwLgaqxqKEgQn5Dw5

Activity

  1. added
    bug
    testing
    priority: low
    on Sep 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugpriority: lowtesting

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions