diff --git a/rsin_driver.hh b/rsin_driver.hh index 8d0c3c7..fe930b6 100644 --- a/rsin_driver.hh +++ b/rsin_driver.hh @@ -45,7 +45,7 @@ class rsin_driver { this->opts = opts; }; - void addFormRSCTLK(std::string *propertyName, FormRSCTLK *f) + void addFormRSCTLK(std::string propertyName, FormRSCTLK *f) { rsctlkform = f; }; diff --git a/rsin_parser.yy b/rsin_parser.yy index efe08c0..81bfb68 100644 --- a/rsin_parser.yy +++ b/rsin_parser.yy @@ -32,7 +32,7 @@ class rsin_driver; %union { int ival; - std::string sval; + std::string *sval; FormRSCTLK *frsctlk; // Entity_f *ent; // Action_f *act; @@ -82,7 +82,8 @@ system: | CONTEXTENTITIES LCB actionentities RCB system | CONTEXTAUTOMATON LCB ctxaut RCB system | RSCTLKFORM LCB IDENTIFIER COL rsctlk_form RCB system { - driver.addFormRSCTLK($3, $5); + driver.addFormRSCTLK(*$3, $5); + free($3); } ;