Skip to content

Commit

Permalink
Fix realm#295
Browse files Browse the repository at this point in the history
  • Loading branch information
norio-nomura committed Dec 28, 2015
1 parent e120984 commit 090c061
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Source/SwiftLintFramework/Rules/ValidDocsRule.swift
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ extension File {
where !comment.containsString(":nodoc:") else {
return substructureOffsets
}
let declaration = contents[Int(offset)..<Int(bodyOffset)]
let declaration = (contents as NSString)
.substringWithByteRange(start: Int(offset), length: Int(bodyOffset - offset))!
let hasViolation = missingReturnDocumentation(declaration, comment: comment) ||
superfluousReturnDocumentation(declaration, comment: comment, kind: kind) ||
superfluousOrMissingThrowsDocumentation(declaration, comment: comment) ||
Expand Down

0 comments on commit 090c061

Please sign in to comment.