php.sugar icon indicating copy to clipboard operation
php.sugar copied to clipboard

String offset operator not recognized properly

Open davisjr opened this issue 15 years ago • 0 comments

The string offset operator is not properly recognized. For eg, in the following code:

private function status_is_error($status)
{
    $status_class = $status{0};
    $error = ($status_class == "4" || $status_class == "5");
    return $error;
}

The sugar thinks the function body ends at the "}" in "$status{0}". Selecting the function in navigator, selects only up to this point. It affects the following methods in the class as well.

davisjr avatar Dec 26 '09 03:12 davisjr