rspec/rules/S1272/cfamily/rule.adoc

17 lines
509 B
Plaintext
Raw Normal View History

== Why is this an issue?
----
setColorPoint(Point p, String Color); //violation
void setColorPoint(Point p, String Color); //Ok
----
If you do not specify a return type, the compiler will assume either void or int, depending on the compiler. You should explicitly declare the return type so that the result will be unambiguous. (Readability)
ifdef::env-github,rspecator-view[]
'''
== Comments And Links
(visible only on this page)
include::comments-and-links.adoc[]
endif::env-github,rspecator-view[]