help-gplusplus
[Top][All Lists]
Advanced

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

Why can switch only compare to const values?


From: Kevin Peterson
Subject: Why can switch only compare to const values?
Date: Fri, 22 Mar 2013 14:34:00 +0000

Just curious:

Take a switch-statement like -

switch(myVar)
{
case(label):
...
break;
}

why label should be constant only?
reply via email to

[Prev in Thread] Current Thread [Next in Thread]