rspec/rules/S2490/rule.adoc
2022-02-04 16:28:24 +00:00

31 lines
445 B
Plaintext

Naming conventions allow teams to collaborate effectively. This rule checks that exception names match a given regular expression.
== Noncompliant Code Example
With the default regular expression ``++[a-zA-Z]([a-zA-Z0-9_]*[a-zA-Z0-9])?++``:
[source,text]
----
DECLARE
my-Exception_ EXCEPTION; -- Noncompliant
BEGIN
NULL;
END;
/
----
== Compliant Solution
[source,text]
----
DECLARE
myException EXCEPTION;
BEGIN
NULL;
END;
/
----