PHP Using $this->variable as Class Method Parameter Default Value

I'm afraid your IDE is correct. This is because "the default value must be a constant expression, not (for example) a variable, a class member or a function call." — Function arguments

You'll need to do something like this:

class something {

    public $somevar = 'someval';

    private function somefunc($default = null) {
        if ($default === null) {
            $default = $this->somevar;
        }
    }
}

This can also be written using the ternary operator:

$default = $default ?: $this->somevar;

"The default value [of a function argument] must be a constant expression, not (for example) a variable, a class member or a function call."

http://php.net/manual/en/functions.arguments.php