Closed Mrockwell2 closed 10 months ago
Also if I assign the value after the MemoryManager declares the variable, it is declared correctly in the checkpoint file.
This is expected. Allocations that are "local" declared, meaning that the memory manager allocates them, appear as declarations in the checkpoint files. Allocations that are "extern" declared, meaning that they allocated outside the memory manager and then registered with a supplied allocation, are not declared in the checkpoint file.
Perhaps I should write some clarifying docs explaining local vs extern allocs? This is the same way that the current Trick memory manager works, but the only difference is supplying the allocation instead of explicitly calling different functions.
Looks like intended behavior
I'm not sure if this is how it's supposed to act, but supplying an allocation when declaring a variable with the MemoryManager leads to it not being declared in the checkpoint file. The following code:
results in a checkpoint file that declares
d
and assigns the values of bothd
andd_ptr
. Notably,d_ptr
is not declared within the file.