unreferenced local?

Started by
5 comments, last by headshot 20 years, 8 months ago
VC++ gives me and warning when i compile, it says this is an unreferenced local var? char buffer[80]; // general printing buffer i''ve just goten back into coding after a few months so maby i forgot something, but it looks fine to me?
i am god!
Advertisement
Since it is a warning I am guessing that it is just informing you that buffer was declared but never accessed/used/referenced.
ASCII stupid question, get a stupid ANSI
does it just want to be set to NULL or something?(yes i know it''s an array)
is it something to worry about(i''m a little warry of warnings)
i am god!
Nah if it really is never being used you might as well just comment it out untill it is needed.
ASCII stupid question, get a stupid ANSI
This error means that you declared buffer, but then never used it for anything. That''s all it means. Why would you declare it, but never reference it in your code?

How appropriate. You fight like a cow.
The compiler is just telling you to use it.
If youre not going to use it then assigning a value to it for the time being will get rid of the warning for now .. but then so will commenting it out.

edit: Wow you guys were quick.

[edited by - Tiffany_Smith on July 28, 2003 2:12:40 PM]
quote:Original post by Sneftel
Why would you declare it, but never reference it in your code?

it''s code from "tricks of the windows..." i just modifyed it a little, but the code he rote was intended as a shell, so i gess it''s understandibal that he would not use it all:D

i am god!

This topic is closed to new replies.

Advertisement