Make a list node out of a stack.
| 633 | |
| 634 | // Make a list node out of a stack. |
| 635 | CompoundStmtNode* PAR_make_list(thread_db* tdbb, StmtNodeStack& stack) |
| 636 | { |
| 637 | SET_TDBB(tdbb); |
| 638 | |
| 639 | // Count the number of nodes. |
| 640 | USHORT count = stack.getCount(); |
| 641 | |
| 642 | CompoundStmtNode* node = FB_NEW_POOL(*tdbb->getDefaultPool()) CompoundStmtNode(*tdbb->getDefaultPool()); |
| 643 | |
| 644 | NestConst<StmtNode>* ptr = node->statements.getBuffer(count) + count; |
| 645 | |
| 646 | while (stack.hasData()) |
| 647 | *--ptr = stack.pop(); |
| 648 | |
| 649 | return node; |
| 650 | } |
| 651 | |
| 652 | |
| 653 | ULONG PAR_marks(Jrd::CompilerScratch* csb) |
no test coverage detected