Add Type and Name analysis to compiler buildProgram()