Skip to content

Release 1.29.0

Choose a tag to compare

@reid-spencer reid-spencer released this 10 Jul 23:07

What's New

Bug Fixes

  • Prettifier round-trips special-character identifiers — RIDDL
    identifiers may be single-quoted to carry special characters (spaces,
    /, @, etc.), e.g. user 'CI/CD Pipeline', and the parser accepts
    that form. The prettifier previously emitted such names unquoted, so
    parse → prettify → parse was not a round-trip — the regenerated RIDDL
    failed to re-parse. Identifier.format now single-quotes any name that
    is not a bare identifier, and the five prettifier sites that rendered
    names via the raw value (including user names — the reported case) now
    go through the quoting path. Bare names (including hyphenated names like
    my-entity) are emitted verbatim, so existing output is unchanged.

Features

  • Whole-path quoting for path identifiers — A path reference whose
    component carries special characters now renders as a single quoted
    path — 'Domain.CI/CD Pipeline.Name' — rather than quoting each
    component. The parser gained a corresponding whole-path quoted form
    (tried after the normal dotted form, so every existing input parses
    unchanged), and the EBNF grammar and generated GBNF grammar were updated
    to match.

  • New public API on IdentifierIdentifier.isBareIdentifier(String)
    reports whether a value is a bare (unquoted) identifier, matching the
    parser's rule exactly ([A-Za-z][A-Za-z0-9_-]*, hyphens included), and
    Identifier.format(String) renders a value as valid RIDDL source
    (quoting when needed). Both are usable on JVM, JS, and Native.

Notes

  • Error messages and diagnostics are unchanged: identify() and message
    templates continue to show names in their own single quotes without
    double-quoting (e.g. Entity 'CI/CD Pipeline'), using the raw value.
  • Additive and backward compatible — no existing signatures changed.
  • Consumers that previously sanitized identifiers before prettifying (to
    work around the missing quoting) can now rely on the prettifier to
    preserve original names.