Skip to content

missing_docs

Ian Applebaum edited this page Jun 13, 2020 · 1 revision

Missing Docs

Declarations should be documented.

  • Identifier: missing_docs
  • Enabled by default: Disabled
  • Supports autocorrection: No
  • Kind: lint
  • Analyzer rule: No
  • Minimum Swift compiler version: 4.1.0
  • Default configuration: warning: open, public

Non Triggering Examples

/// docs
public class A {
/// docs
public func b() {}
}
/// docs
public class B: A { override public func b() {} }
import Foundation
/// docs
public class B: NSObject {
// no docs
override public var description: String { fatalError() } }
/// docs
public class A {
    deinit {}
}
public extension A {}

Triggering Examples

public func a() {}
// regular comment
public func a() {}
/* regular comment */
public func a() {}
/// docs
public protocol A {
// no docs
var b: Int { get } }
/// docs
public struct C: A {

public let b: Int
}
Clone this wiki locally