rspec/rules/S119/swift/rule.adoc

22 lines
321 B
Plaintext
Raw Normal View History

2020-06-30 10:16:44 +02:00
include::../description.adoc[]
== Noncompliant Code Example
2021-01-27 13:42:22 +01:00
With the default regular expression ``++^[A-Z]$++``:
2020-06-30 10:16:44 +02:00
----
public class MyClass<TYPE> { // Noncompliant
func method<TYPE>(t : TYPE) { // Noncompliant
}
}
----
== Compliant Solution
----
public class MyClass<T> {
func method<T>(t : T) {
}
}
----