1. A method for hierarchical program source management, comprising: retrieving a main program from a memory; initiating a layer representing a portion of the main program for editing on a display; editing program code within the layer in response to detected user programming inputs; generating a layer abstract syntax tree corresponding to the edited program code; comparing the layer abstract syntax tree with a main program abstract syntax tree; and generating a layer file comprising differences between the layer abstract syntax tree and the main program abstract syntax tree.