More on type qualifiers ignored on function return type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have read up on this warning on the newsgroup and google. I understand the reasoning behind adding the warning, however; it is having a rather sad affect on our code base, which use to compile warning free (on Linux) with the 3.x compiler but now we get more warnings then stars in the night sky ;)

Basically we had been using the const qualifier on some function return types as informative to the user of API that the return value should not be freed or modified.

So the primary question is: is there a compiler switch we can use to stop this specific warning from being displayed?

second, and obviously off topic, If we wanted to change our code what would you recommend to indicate that the return value should not be modified or freed (I read a little about __attribute__const but didn't really follow what it was for exactly).

Thanks - I hope this is a bit more intelligent then my last post :(

-Jim


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux