Skip to content

MLX rejects standard {|...|} strings: '' cannot be used as a quoted string delimiter #37

Description

@davesnx

Versions

  • mlx: PR OCaml 5.4 #29, commit 32da854e4cfbd7da7e126f3c081b68924f5f9462
  • OCaml: 5.5.0

Problem

mlx-pp rejects standard OCaml quoted strings that use an empty delimiter.

Reproduction

mlx-pp -print-ml <<'MLX'
let css = {|color: red;|}
MLX

Actual result:

Error: '' cannot be used as a quoted string delimiter,
it must contain only lowercase letters.

The same input is accepted by mlx 0.11 and by OCaml.

Impact

In a scan of 6,829 tracked Reason files converted to MLX, 2,062 outputs were rejected for this reason. It also breaks the monorepo build for existing MLX files in Siren, Grafana dashboards, and HQ.

Expected behavior is for {|...|} to parse as a quoted string with the standard empty delimiter.

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions