whatwg / urlpattern

URL Pattern Standard
https://urlpattern.spec.whatwg.org/
Other
159 stars 22 forks source link

Steps `create a component match result` never increments index #173

Closed tjosepo closed 2 years ago

tjosepo commented 2 years ago

Tiny issue I noticed in the loop of https://wicg.github.io/urlpattern/#create-a-component-match-result, while working on an implementation:

  1. Let index be 1.
  2. While index is less than Get(execResult, "length"):
    1. Let name be component’s group name list[index − 1].
    2. Let value be Get(execResult, ToString(index).
    3. Set groups[name] to value.

index is never incremented, and the loop will never end.

wanderview commented 2 years ago

Thanks for catching this!