There was a problem when chrome,js was debugging in debug. Is this chrome's bug?

clipboard.png
when the following line is commented out, the console print scope will report an error
, but when it is released, it will print out
I understand that the inside should hold a reference to the outer scope, whether there is the following line or not.
is this the optimization mechanism of chrome?

Mar.10,2021

although it may be a good habit to be skeptical, I still want to say that don't always doubt whether this is a bug, especially for a mature tool like chrome, even if you have bug, it is almost impossible for you to find it, especially in such a simple scenario.

this is a basic feature of closures. The inner scope does have access to variables in the outer scope, but only if a closure is formed (except for global variables). After you comment out, the scope is no longer in the closure and is of course inaccessible.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b35ecf-2bfdc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b35ecf-2bfdc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?