You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Have SomeEnum defined in another file (in this case src/constants.ts)
This part I have not fully figured out the exact cases but please bear with me
If the lengths of the 2 files match some (currently) unknown condition, the call to generateCodeFrame will get stuck in an infinite loop in its inner for loop.
Vue version
3.4.26
Link to minimal reproduction
https://github.com/aturingmachine/vue-sfc-infinite-loop
Steps to reproduce
Have a component making use of a Generic in it's Props that extends an
enum
.i.e. (this is pulled from the linked reproduction)
Have
SomeEnum
defined in another file (in this casesrc/constants.ts
)If the lengths of the 2 files match some (currently) unknown condition, the call to
generateCodeFrame
will get stuck in an infinite loop in its innerfor
loop.Link to Line in Question
What is expected?
That the compiler will report the error at the correct lines.
What is actually happening?
The Compiler gets stuck in an infinite loop and hangs indefinitely.
System Info
Any additional comments?
This issue has been brought up once and resolved seen here.
The issue can be "resolved" by reducing the number of lines in either the Component file or the file containing the Enum.
It seems the case
j >= lines.length
on line 26 leading to thecontinue
trips the infinite loop, but I may be wrong.The provided reproduction link is a simplified version of our production code that triggered the initial issue.
The text was updated successfully, but these errors were encountered: