1
0
mirror of https://github.com/aportelli/LatAnalyze.git synced 2025-12-22 08:54:28 +00:00

Compiled function: access to source code

This commit is contained in:
2014-09-29 15:10:38 +01:00
parent bbeaec9ed3
commit bf3fe8bd13
4 changed files with 19 additions and 3 deletions

View File

@@ -39,7 +39,8 @@ public:
// destructor
virtual ~CompiledDoubleModel(void) = default;
// access
void setCode(const std::string &code);
std::string getCode(void);
void setCode(const std::string &code);
// function call
using DoubleModel::operator();
virtual double operator()(const double *arg, const double *par) const;
@@ -50,6 +51,7 @@ private:
// compile
void compile(void) const;
private:
std::string code_;
std::shared_ptr<MathInterpreter> interpreter_;
std::shared_ptr<RunContext> context_;
std::shared_ptr<std::vector<unsigned int>> varAddress_, parAddress_;