SyntaxWarning in compile indicates invalid input

closes #5663