Unreferenced variable: Difference between revisions

Content deleted Content added
Cydebot (talk | contribs)
m Robot - Speedily moving category Variable (computer programming) to Category:Variable (computer science) per CFDS.
top: Split and expand sentence. Added placeholder usage
Line 1:
{{Unreferenced|date=February 2007}}
An '''unreferenced variable''' in the [[source code]] of a [[computer program]] is a [[Variable (programming)|variable]] that is defined but which is never used. This may result in a harmless waste of memory. (unless theMany [[compiler]]s useddetect detects thesuch situationvariables and doesdo not allocate storage for thethem variable(i.e., perhaps"optimize away" their storage), generally also issuing a warning). as they do.

Some [[coding style|coding guideline]] documents consider an unreferenced variable to be a symptom of a potential coding fault. On the other hand, unreferenced variables can be used as temporary placeholders to indicate further expected future developments in the code.
 
==Examples==