(str, pos, dir)
| 823 | |
| 824 | // Returns a number from the range [`0`; `str.length`] unless `pos` is outside that range. |
| 825 | function skipExtendingChars(str, pos, dir) { |
| 826 | while ((dir < 0 ? pos > 0 : pos < str.length) && isExtendingChar(str.charAt(pos))) { |
| 827 | pos += dir |
| 828 | } |
| 829 | return pos |
| 830 | } |
| 831 | |
| 832 | // Returns the value from the range [`from`; `to`] that satisfies |
| 833 | // `pred` and is closest to `from`. Assumes that at least `to` |
no test coverage detected