rspec/rules/S2371/rule.adoc

44 lines
872 B
Plaintext
Raw Permalink Normal View History

== Why is this an issue?
Reserved parameters are unnecessary in VB.NET because method overloading can be used to introduce additional variants over time.
2021-02-02 15:02:10 +01:00
2021-01-27 13:42:22 +01:00
This rule detects parameters which contain ``++reserved++`` in their names.
=== Noncompliant code example
2022-02-04 17:28:24 +01:00
[source,text]
----
Module Module1
Function Add(ByVal a As Integer, ByVal b As Integer, ByVal reserved As Integer) As Integer ' Noncompliant
Return a + b
End Function
End Module
----
=== Compliant solution
2022-02-04 17:28:24 +01:00
[source,text]
----
Module Module1
Function Add(ByVal a As Integer, ByVal b As Integer) As Integer ' Compliant
Return a + b
End Function
End Module
----
2022-01-25 18:36:46 +01:00
ifdef::env-github,rspecator-view[]
'''
== Implementation Specification
(visible only on this page)
=== Message
Remove "reserved" parameter "xxx".
2022-01-25 18:36:46 +01:00
endif::env-github,rspecator-view[]