Still in progress. Nothing workds.
This commit is contained in:
parent
aa5b34368e
commit
ef59563e25
14 changed files with 206 additions and 180 deletions
|
|
@ -10,6 +10,7 @@
|
|||
#include "memory/node.h"
|
||||
#include "memory/pso2.h"
|
||||
#include "memory/pso4.h"
|
||||
#include "memory/tags.h"
|
||||
#include "payloads/stack.h"
|
||||
|
||||
/**
|
||||
|
|
@ -21,6 +22,8 @@ uint32_t stack_limit = 0;
|
|||
|
||||
/**
|
||||
* Fetch a pointer to the value of the local variable at this index.
|
||||
*
|
||||
* TODO: I think the first argument would be better as a pso_pointer.
|
||||
*/
|
||||
struct pso_pointer fetch_arg( struct pso4 *frame, unsigned int index ) {
|
||||
struct pso_pointer result = nil;
|
||||
|
|
@ -40,3 +43,15 @@ struct pso_pointer fetch_arg( struct pso4 *frame, unsigned int index ) {
|
|||
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Return the environment from the stack frame identified by this
|
||||
* `frame_pointer`
|
||||
*
|
||||
* @param frame_pointer a pointer to a stack frame.
|
||||
*/
|
||||
struct pso_pointer fetch_env( struct pso_pointer frame_pointer) {
|
||||
return stackp(frame_pointer) ?
|
||||
pointer_to_pso4(frame_pointer)->payload.stack_frame.env :
|
||||
nil;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue