turned split() into a hyper-op

pull/95/head
jmoenig 2020-04-22 13:45:45 +02:00
rodzic 18e8131711
commit e10fc51ed9
1 zmienionych plików z 17 dodań i 0 usunięć

Wyświetl plik

@ -3756,6 +3756,23 @@ Process.prototype.reportUnicodeAsLetter = function (num) {
};
Process.prototype.reportTextSplit = function (string, delimiter) {
if (this.enableHOO) {
if (string instanceof List) {
return new List(
string.asArray().map(
each => this.reportTextSplit(each, delimiter)
)
);
}
if (delimiter instanceof List) {
return new List(
delimiter.asArray().map(
each => this.reportTextSplit(string, each)
)
);
}
}
var types = ['text', 'number'],
strType = this.reportTypeOf(string),
delType = this.reportTypeOf(this.inputOption(delimiter)),