reasonml / reasonml/reason

v4 syntax TODO

Open
#2,672 0 comments 28 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
OCaml
Stars
10.3k
Forks
438
PR merge metrics
No merged PRs in 30d

Description

Here is the current stack of diffs for v4 features.

This task list tracks the remaining items that make sense to do in a breaking release.

  • Support for reason version tagging at start of file [@reason.version 3.7];
  • String template support using backticks like ES6, and polymorphic variants now use tag syntax #LikeThis.
  • String template literals normalize leading whitespace unlike ES6.
  • Type parameters use angle brackets type doubleList<'t> = list<('t, 't)>.
  • Automatically update entire reason file to v4 editor if detecting use of angle brackets for type parameters.
  • Fix parsing precedence of string concatenation ++ and various operators to be left biased in the AST so that x ++ y ++ z is (x++y) ++ z.
  • Figure out how to interpolate printing of types in string literals. Should we use the same construct as printf for this?
        let x = `
          By default a string is expected here ${someVariableThatIsAString}
          But what about an integer %d{int here}
          And what about a custom datatype %%{myCustomDataType, printer}
        `
  • Decide identifier renaming (or not) scheme once and for all to avoid all identifier conflicts/ambiguity with ocaml identifiers.
  • { } should not be an empty object and not be the empty object type. Should possibly be unit in expression and something else in types. Empty objects are seldom used.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked pull-request commit stack for the v4 features and compare it with each unchecked item in this issue. Determine the affected parser, printer, and identifier-handling entry points before taking on one remaining item; done means the selected syntax behavior is decided and implemented with appropriate coverage.

Written by the indexing model from the issue text.

Assessment

Tech stack
ocaml
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.