In spite of affecting a good number of files, this PR does a simple change: it gets rid of the accept() methods in the term/formula FSTRIPS hierarchy, which were doing a redundant job: simply calling the visitor visit() method. That is standard in C++ visitor implementations, but it is not necessary in Python, since the visitor is doing all of the job by calling isinstance anyway. This should not break anything, and tests are passing OK.
I also implemented, as a proof of concept, a term_substitution "wrapper" that offers a cleaner interface to the calling methods that want to compute a term substitution. We could do the same with other transformations, but I didn't want to complicate this PR further.
In spite of affecting a good number of files, this PR does a simple change: it gets rid of the
accept()
methods in the term/formula FSTRIPS hierarchy, which were doing a redundant job: simply calling the visitorvisit()
method. That is standard in C++ visitor implementations, but it is not necessary in Python, since the visitor is doing all of the job by callingisinstance
anyway. This should not break anything, and tests are passing OK.I also implemented, as a proof of concept, a
term_substitution
"wrapper" that offers a cleaner interface to the calling methods that want to compute a term substitution. We could do the same with other transformations, but I didn't want to complicate this PR further.