| 273 | } |
| 274 | |
| 275 | void fxScopeHoisted(txScope* self, txHoister* hoister) |
| 276 | { |
| 277 | if (self->token == XS_TOKEN_BLOCK) { |
| 278 | txDeclareNode** address = &self->firstDeclareNode; |
| 279 | txDeclareNode* node; |
| 280 | txDeclareNode* last = C_NULL; |
| 281 | while ((node = *address)) { |
| 282 | if (node->description->token == XS_NO_TOKEN) { |
| 283 | self->declareNodeCount--; |
| 284 | *address = node->nextDeclareNode; |
| 285 | } |
| 286 | else { |
| 287 | address = &node->nextDeclareNode; |
| 288 | last = node; |
| 289 | } |
| 290 | } |
| 291 | self->lastDeclareNode = last; |
| 292 | } |
| 293 | else if (self->token == XS_TOKEN_PROGRAM) { |
| 294 | txDeclareNode* node = self->firstDeclareNode; |
| 295 | while (node) { |
| 296 | if ((node->description->token == XS_TOKEN_DEFINE) || (node->description->token == XS_TOKEN_VAR)) |
| 297 | self->declareNodeCount--; |
| 298 | node = node->nextDeclareNode; |
| 299 | } |
| 300 | } |
| 301 | else if (self->token == XS_TOKEN_EVAL) { |
| 302 | if (!(self->flags & mxStrictFlag)) { |
| 303 | txDeclareNode* node = self->firstDeclareNode; |
| 304 | while (node) { |
| 305 | if ((node->description->token == XS_TOKEN_DEFINE) || (node->description->token == XS_TOKEN_VAR)) |
| 306 | self->declareNodeCount--; |
| 307 | node = node->nextDeclareNode; |
| 308 | } |
| 309 | } |
| 310 | } |
| 311 | hoister->scope = self->scope; |
| 312 | } |
| 313 | |
| 314 | void fxScopeLookup(txScope* self, txAccessNode* access, txBoolean closureFlag) |
| 315 | { |
no outgoing calls
no test coverage detected