gi: support freeing struct return type everything