Reason: Flip list and array syntax to increase JavaScript-familiarity

Created on 20 Jan 2018  路  3Comments  路  Source: reasonml/reason

If the array syntax was:

[1, 2, 3]

And the list syntax was:

[|1, 2, 3|]

... I wonder if that would aide in onboarding JS devs? It seems like arrays will be much more used anyway.

FEATURE REQUEST Parser

Most helpful comment

IME, lists are far more useful in OCaml, because you can't change the size of arrays.

All 3 comments

IME, lists are far more useful in OCaml, because you can't change the size of arrays.

Immutability is a really important concept in reason. Lists are immtable which is why they are chosen over arrays.

Array is only used more when compiling to JS, list is more useful in OCaml.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

chenglou picture chenglou  路  3Comments

modlfo picture modlfo  路  4Comments

kyldvs picture kyldvs  路  3Comments

rickyvetter picture rickyvetter  路  3Comments

chenglou picture chenglou  路  3Comments