arduino / Arduino

Arduino IDE 1.x
https://www.arduino.cc/en/software
Other
14.07k stars 7.01k forks source link

Missing header file is not reported at compile (or verify) time #1508

Closed michaelshiloh closed 10 years ago

michaelshiloh commented 10 years ago

If a header file is missing or miss-spelled, it is not reported.

This seems wrong.

(The compile will very likely fail later due to undefined variables, and this does generate error messages, but the real error is the missing header file, so the error message is very misleading, especially for beginners.)

I'm using 1.0.5 on Linux; verified also on Mac OS (also using 1.0.5)

If I turn on verbose output, there is a warning that the header file can't be found. This warning should be reported even when verbose output is suppressed.

lestofante commented 10 years ago

This is a compiler bug, not ide

2013/7/16 michaelshiloh notifications@github.com

If a header file is missing or miss-spelled, it is not reported.

This seems wrong.

(The compile will very likely fail later due to undefined variables, and this does generate error messages, but the real error is the missing header file, so the error message is very misleading, especially for beginners.)

I'm using 1.0.5 on Linux; verified also on Mac OS (also using 1.0.5)

If I turn on verbose output, there is a warning that the header file can't be found. This warning should be reported even when verbose output is suppressed.

— Reply to this email directly or view it on GitHubhttps://github.com/arduino/Arduino/issues/1508 .

matthijskooijman commented 10 years ago

Isn't this a problem with the flags passed to the compiler, really? I don't have the Arduino IDE at hand to check, but I'd guess this is related to the -w (suppress warnings) or -Werror (treat warnings as errors) flags or something like that...

michaelshiloh commented 10 years ago

Either way, it should be reported to the user

On 07/16/2013 01:12 AM, lestofante wrote:

This is a compiler bug, not ide

2013/7/16 michaelshiloh notifications@github.com

If a header file is missing or miss-spelled, it is not reported.

This seems wrong.

(The compile will very likely fail later due to undefined variables, and this does generate error messages, but the real error is the missing header file, so the error message is very misleading, especially for beginners.)

I'm using 1.0.5 on Linux; verified also on Mac OS (also using 1.0.5)

If I turn on verbose output, there is a warning that the header file can't be found. This warning should be reported even when verbose output is suppressed.

— Reply to this email directly or view it on GitHubhttps://github.com/arduino/Arduino/issues/1508 .


Reply to this email directly or view it on GitHub: https://github.com/arduino/Arduino/issues/1508#issuecomment-21027313

Michael Shiloh
teachmetomake.com/wordpress KA6RCQ

Educational Materials coordinator at Arduino.cc Electronics, Robotics, Digital Fabrication, and Arduino educator California College of the Arts San Francisco Art Institute San Francisco State University

michaelshiloh commented 10 years ago

Either way, it should be fixed.

On 07/16/2013 02:17 AM, Matthijs Kooijman wrote:

Isn't this a problem with the flags passed to the compiler, really? I don't have the Arduino IDE at hand to check, but I'd guess this is related to the -w (suppress warnings) or -Werror (treat warnings as errors) flags or something like that...


Reply to this email directly or view it on GitHub: https://github.com/arduino/Arduino/issues/1508#issuecomment-21030273

Michael Shiloh
teachmetomake.com/wordpress KA6RCQ

Educational Materials coordinator at Arduino.cc Electronics, Robotics, Digital Fabrication, and Arduino educator California College of the Arts San Francisco Art Institute San Francisco State University

lestofante commented 10 years ago

Sorry but the ide does not play with compiler messages. But if I'm right you can activate verbose compiler mode in the preferencies, it does print warning. If a header is mispelled it is relatively easy to recognize, missing header is almost impossible without going throug all header looking for your "object". Il giorno 16/lug/2013 21:13, "michaelshiloh" notifications@github.com ha scritto:

Either way, it should be reported to the user

On 07/16/2013 01:12 AM, lestofante wrote:

This is a compiler bug, not ide

2013/7/16 michaelshiloh notifications@github.com

If a header file is missing or miss-spelled, it is not reported.

This seems wrong.

(The compile will very likely fail later due to undefined variables, and this does generate error messages, but the real error is the missing header file, so the error message is very misleading, especially for beginners.)

I'm using 1.0.5 on Linux; verified also on Mac OS (also using 1.0.5)

If I turn on verbose output, there is a warning that the header file can't be found. This warning should be reported even when verbose output is suppressed.

— Reply to this email directly or view it on GitHub< https://github.com/arduino/Arduino/issues/1508> .


Reply to this email directly or view it on GitHub: https://github.com/arduino/Arduino/issues/1508#issuecomment-21027313

Michael Shiloh teachmetomake.com/wordpress KA6RCQ

Educational Materials coordinator at Arduino.cc Electronics, Robotics, Digital Fabrication, and Arduino educator California College of the Arts San Francisco Art Institute San Francisco State University

— Reply to this email directly or view it on GitHubhttps://github.com/arduino/Arduino/issues/1508#issuecomment-21065652 .

ffissore commented 10 years ago

This is caused by the -w flag on the compiler command line, which keeps warnings from being reported. Closing as duplicate of #1728