improve code readability: duplicate local var of child
improve code readability: duplicate local var of child

Closes: #1022
Approved by: huitseeker

aptos-labs/aptos-core,aptos-labs/aptos-core,aptos-labs/aptos-core,libra/libra,aptos-labs/aptos-core,libra/libra,libra/libra,aptos-labs/aptos-core,aptos-labs/aptos-core,libra/libra,aptos-labs/aptos-core,libra/libra