Found by the package matrix re-run (#11723): node-forge/rsa_sign throws TypeError: … (reading 'data'). Reproduces 3/3 at 9e29f59 and on origin/main 9e05951.
Inside a do…while body, this is undefined in any non-class function. A plain while loop works, and so does a class method.
const o = { d: 7, f(n) { let r = 0; do { r += this.d; n--; } while (n > 0); return r; } };
console.log(o.f(1)); // node: 7; perry: throws TypeError
Found by the package matrix re-run (#11723):
node-forge/rsa_signthrowsTypeError: … (reading 'data'). Reproduces 3/3 at 9e29f59 and on origin/main 9e05951.Inside a
do…whilebody,thisisundefinedin any non-class function. A plainwhileloop works, and so does a class method.