0

The following function returns an object in coco:

->
  a: "1"
  b: "2"

The next will result in multiple statements and returns the result of the last one (as expected):

->
  "a"
  "b"

How to return an array without using brackets? I was trying this:

->
  * "a"
  * "b"

However now it also compiles again into multiple statements.

Is it possible now in coco?

@matyr: Or will it be possible?

UPDATE: I am currently using following syntax, but it is not so clean:

-> []=
  "a"
  "b"
TN.
  • 18,874
  • 30
  • 99
  • 157

1 Answers1

1

Just on whatever case someone comes on this, this is totally valid :

->
 * a
   b
Ven
  • 19,015
  • 2
  • 41
  • 61