added possibility to serialize closures