api generator: c++: fix getProperty typed return