help-octave
[Top][All Lists]
Advanced

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

Re: warning: variable switch label


From: Søren Hauberg
Subject: Re: warning: variable switch label
Date: Sun, 02 Jul 2006 11:33:03 +0200

lør, 01 07 2006 kl. 11:26 -0400, skrev John W. Eaton:
> The evaluator is trying to tell you that the expression
> 
>   {"a", "b"}
> 
> is not a constant.  It's not constant because the parser is not
> converting that list expression to a constant cell object internally.
> That's a minor bug that is easily fixed by the following patch.
I see, thanks. I looked at warning_ids and found
`Octave:variable-switch-label', which I assume is the warning I got. If
so, then there's another bug because this warning is disabled.

> I copied this warning from GCC without thinking too much about it.
> In C, I think a variable switch label is nonstandard.  For Octave,
> there is no standard, so we can warn or not.  Should we?
I think the warning makes sense, so I'd say keep it.

Søren




reply via email to

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