Skip to content

Commit

Permalink
Removed reference to bug ID
Browse files Browse the repository at this point in the history
  • Loading branch information
SquaredTiki committed Jan 12, 2016
1 parent 429524a commit 6b7eb00
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/Parse/ParsePattern.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,16 +238,15 @@ Parser::parseParameterClause(SourceLoc &leftParenLoc,
// Check if token is @ sign ergo an attribute
if (Tok.is(tok::at_sign)) {
Token nextToken = peekToken();
// Fix for SR215
// Check if attribute is invalid type attribute
// Check if attribute is invalid type attribute
// and actually a declaration attribute
if (TypeAttributes::getAttrKindFromString(nextToken.getText()) == TAK_Count
&& DeclAttribute::getAttrKindFromString(nextToken.getText()) != TAK_Count) {
SourceLoc AtLoc = consumeToken(tok::at_sign);
SourceLoc AttrLoc = consumeToken(tok::identifier);
diagnose(AtLoc, diag::decl_attribute_applied_to_type)
.fixItRemove(SourceRange(AtLoc, AttrLoc))
.fixItInsert(StartLoc, "@" + nextToken.getText().str()+" ");
.fixItInsert(StartLoc, "@" + nextToken.getText().str()+" ");
}
}

Expand Down

0 comments on commit 6b7eb00

Please sign in to comment.