You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would normally format anonymous classes like the following example:
<?phpnamespaceExample;
class Example
{
publicfunction__construct()
{
$this->foo(newclass {
publicfunctionbar()
{
}
}); // <-- New error message: "Closing class brace must be on a line by itself"
}
publicfunctionfoo($input)
{
}
}
There doesn't seem to be any way to solve this while still satisfying other rules. If I move the closing parenthesis onto the next line, I get error message "Expected 0 spaces before closing bracket; newline found".