Commit fc7cd258 authored by Christian Kamm's avatar Christian Kamm
Browse files

QmlJS checks: Make 'unintentional empty block' warning less annoying.

Already fixed differently in master.

Change-Id: I92f7665166b2b1ca4f3d4598825b04f3f19d4772
Reviewed-by: default avatarChristian Kamm <>
parent a64ca516
......@@ -970,8 +970,7 @@ bool Check::visit(Block *ast)
warning(ast->lbraceToken, tr("blocks do not introduce a new scope, avoid"));
if (!ast->statements
&& (cast<UiPublicMember *>(p)
|| cast<UiScriptBinding *>(p))) {
&& cast<UiPublicMember *>(p)) {
warning(locationFromRange(ast->firstSourceLocation(), ast->lastSourceLocation()),
tr("unintentional empty block, use ({}) for empty object literal"));
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment