"abc"<-Array.prototype.map((c) => c);
var uint8array: Uint8Array;
var array = uint8array<-Array.prototype.map((i) => i);
Compiles to:
Array.prototype.map.call("abc", function (c) { return c; });
var uint8array;
var array = Array.prototype.map.call(uint8array, function (i) { return i; });
In conjunction with extension functions
function map(callbackfn: (value: any, index: number, array: Uint8Array) => number) joins {} {
return Array.prototype.map.call(this, callbackfn);
}
"abc"<-map((c) => c);
var uint8array: Uint8Array;
var array = uint8array<-map((i) => i);
Compiles to
function map(_this, callbackfn) {
return Array.prototype.map.call(_this, callbackfn);
}
map("abc", function (c) { return c; });
var uint8array;
var array = map(uint8array, function (i) { return i; });