bug(function_node): Added missing code.
refactor(function_node/generator_node): Added more asserts.