power-assert-js/power-assert

Missing * with async generator methods

falsandtru opened this issue · 9 comments

// input
({
  async *g() {},
  async *[Symbol.asyncIterator]() {},
})
class C {
  async *g() {}
  async *[Symbol.asyncIterator]() {}
}
// output
({
  async g() {},
  async [Symbol.asyncIterator]() {},
})
class C {
  async g() {}
  async [Symbol.asyncIterator]() {}
}
twada commented

It's nothing to do with power-assert but It's a escodegen's problem. I'm working on it.

twada commented

FYI: Just made a pull-req to escodegen
estools/escodegen#375

Thanks.

@twada Looks like that fix isn't reflected because the dependencies and package-lock.json aren't updated. Can you update them and bump the version?

twada commented

@falsandtru

  1. I'm using optimistic semver range (a.k.a ^)
  2. package-lock.json only affects top-level install, and package-lock.json is removed from npm module on publish

So something is strange. I'm okay to bump and release but it's not a best solution here. We should rely on semver range.

Would you try cleaning node_modules and package-lock.json up and install again?

Resolved. I'd tried to remove and install power-assert but it wasn't enough. Thanks.

twada commented

@falsandtru Glad to hear that 👍