We solved this by using `std::vector<RCP<const Basic>>` and documented this issue in the `functions.h` file.