We had this problem too. We found the message was for line 0 even though our "syntax error" was on line 30. I say "syntax error" in quotes because the issue was an IAR linker directive that the compiler accepted just fine, but wasn't standard C. Once we found another way to express the syntax, the line 0 error went away.