firefly-compiler 0.5.6 → 0.5.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/core/List.ff CHANGED
@@ -231,7 +231,7 @@ extend self[T]: List[T] {
231
231
  await body_(self_[i], $task)
232
232
  }
233
233
  """
234
-
234
+
235
235
  eachWhile(body: T => Bool): Unit
236
236
  target js sync "for(const value of self_) if(!body_(value)) break"
237
237
  target js async "for(const value of self_) if(!await body_(value, $task)) break"
@@ -308,19 +308,6 @@ extend self[T]: List[T] {
308
308
  return result;
309
309
  """
310
310
 
311
- map2[S](body: T => S): List[S] {
312
- if(!UnsafeJs.inAsync()) {
313
- self!->map(body!)?
314
- } else {
315
- let result = Array.new()
316
- 0.until(self.size()).each {i =>
317
- result.push(body(self.grab(i)))
318
- }
319
- result.drain()
320
- }
321
- }
322
-
323
-
324
311
  flatMap[S](body: T => List[S]): List[S] {
325
312
  let results = Array.new()
326
313
  self.each {x =>
@@ -377,7 +364,7 @@ extend self[T]: List[T] {
377
364
  }
378
365
  array.drain()
379
366
  }
380
-
367
+
381
368
  }
382
369
 
383
370
  extend self[T: Order]: List[T] {