reconstruct the code structure