Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

106
Views
La operación LexicallyScopedDeclarations no tiene sentido

supongamos que tenemos una función y dentro de esa función, tenemos una declaración let en el nivel más alto de la función.

ahora ejecutamos FunctionDeclarationInstantiation , pero aquí viene la parte extraña, observe el paso 33 .

Deje que lexDeclarations sea LexicallyScopedDeclarations del código.

así que invocamos la operación LexicallyScopedDeclarations con el nodo de análisis FunctionBody .

por lo tanto, ejecutamos la definición del algoritmo implícito (porque no hay un algoritmo para la producción de FunctionBody )

 FunctionBody:FunctionStatementList Return LexicallyScopedDeclarations of FunctionStatementList

entonces llegamos a este algoritmo

 FunctionStatementList:StatementList Return the TopLevelLexicallyScopedDeclarations of StatementList.

y ahí es donde comienza mi confusión , porque ahora cuando invocamos TopLevelLexicallyScopedDeclarations con StatementList

y llegaremos aquí

 StatementList : StatementList StatementListItem 1. Let declarations1 be TopLevelLexicallyScopedDeclarations of StatementList. 2. Let declarations2 be TopLevelLexicallyScopedDeclarations of StatementListItem. 3. Return the list-concatenation of declarations1 and declarations2.

finalmente, eso nos llevará a este algoritmo

 StatementListItem : Declaration 1. If Declaration is Declaration : HoistableDeclaration , then a. Return a new empty List. 2. Return « Declaration ».

ahora, ¿cómo se supone que obtendremos la variable let que mencioné anteriormente, si el paso 1 dice que si esa Declaración es una Declaración: HoistableDeclaration, entonces devolvemos una lista vacía?

no tiene ningún sentido para mí.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!