menu
no-unnecessary-slice-end
Disallow slice end arguments that cannot shorten the result
Passing the source length or positive infinity as a slice end selects every remaining value. Instead, you SHOULD omit an end argument that cannot shorten the result.
Reported
1function tail(values: int32[]): int32[] {2 return values.slice(1, values.length as isize);3}Accepted
1function tail(values: int32[]): int32[] {2 return values.slice(1);3}