(mode)
| 2521 | } |
| 2522 | |
| 2523 | function modeNum(mode) { |
| 2524 | // eslint-disable-next-line no-self-compare |
| 2525 | if (typeof mode === 'number' && mode === mode) // Valid, non-NaN number |
| 2526 | return mode; |
| 2527 | if (typeof mode === 'string') |
| 2528 | return modeNum(parseInt(mode, 8)); |
| 2529 | throw new Error(`Cannot parse mode: ${mode}`); |
| 2530 | } |
| 2531 | |
| 2532 | const stringFlagMap = { |
| 2533 | 'r': OPEN_MODE.READ, |
no outgoing calls
no test coverage detected
searching dependent graphs…