Trouble:Bad Binary Operator Placement

From HyPhy Wiki
Revision as of 21:52, 2 November 2011 by Art Poon (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

caption

In this particular example, HyPhy failed to parse the following "if" conditional statement:

if (match[0] > -1)
{
    ...
}

The problem is that HyPhy is reading the "greater than" sign and the "minus" sign as a single binary operator, which it does not recognize. To fix this, you need to enclose the -1 in parentheses, like this:

if (match[0] > (-1))
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox