Fixed: [Issue 148] Elements with different types bug same names are marked as errors. Cleaned up code.