track current script body's priority as well as its AST

This commit is contained in:
Vern Paxson 2021-04-19 16:08:45 -07:00
parent 00d66f1ac2
commit 3796e2508b
2 changed files with 8 additions and 4 deletions

View file

@ -239,6 +239,7 @@ public:
detail::StmtPtr new_body);
StmtPtr CurrentBody() const { return current_body; }
int CurrentPriority() const { return current_priority; }
/**
* Returns the function's frame size.
@ -307,8 +308,11 @@ private:
OffsetMap* captures_offset_mapping = nullptr;
// The most recently added/updated body.
// The most recently added/updated body ...
StmtPtr current_body;
// ... and its priority.
int current_priority;
};
using built_in_func = BifReturnVal (*)(Frame* frame, const Args* args);