version 3.15.0 - improved pip_cmg and PICodeInfo storage

Important! changed API to access PICodeInfo storage
This commit is contained in:
2023-12-08 16:14:18 +03:00
parent 49a5ed6aa3
commit b8fc44714c
5 changed files with 130 additions and 55 deletions

View File

@@ -4,13 +4,29 @@
#include "pijson.h"
#include "pimathbase.h"
#include "pip.h"
#include "piplugin.h"
#include "pivaluetree.h"
#include "test_plugin_shared.h"
using namespace PICoutManipulators;
int main(int argc, char * argv[]) {
PICodeParser cp;
cp.parseFile("kmm_types.h", false);
PIPluginLoader loader;
for (int j = 0; j < 2; ++j) {
piCout << "\nITER" << j;
loader.load("pip_plugin");
auto f = loader.resolve("myFunc");
if (f) {
PIMap<int, MyFunc> funcs;
((void (*)(PIMap<int, MyFunc> &))f)(funcs);
piCout << "size =" << funcs.size();
for (auto i: funcs) {
piCout << i.first;
i.second();
}
}
loader.unload();
}
return 0;
}