chmotori 0 Posted April 2, 2009 Report Share Posted April 2, 2009 Hi, I don't know if it's a bug, but it's a bit annoying, that the boostC compiler (6.93RC2) only report a warning when i use the syntax: structVar->element where it's supposed to be: structVar.element since structVar is a struct variable, not a pointer to a struct. It's annoying especially because, when compiling ten or more files, the warnings are reported only at compile time, and are not summarized after the linker has finished. Regards, Elpidio Quote Link to post Share on other sites
Pavel 0 Posted April 2, 2009 Report Share Posted April 2, 2009 The short answer to your question is that yes compiler should report an error for such cases. The reason it reports a warning is that when the check for this condition was added to compiler it was too risky to make it an error because if the check (that is quite complex) does something wrong and reports a false positive a good code may stop compiling. However since this check was included into the public compiler releases we never received any reports about false positives. Probably it's time to make compiler report an errors for such cases. Regards, Pavel Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.