== Why is this an issue?

include::../description.adoc[]

=== Noncompliant code example

[source,cpp]
----
class Example {
public:
  void foo(int x); // NonCompliant
  void notFoo(int x);
  void foo(double x); // Should be moved next to its overload
private:
  void foo(long x); // Okay since the function has different access specifier
};
----

=== Compliant solution

[source,cpp]
----
class Example {
public:
  void foo(int x); // Compliant
  void foo(double x);
  void notFoo(int x);
private:
  void foo(long x); // Okay since the function has different access specifier
};
----
ifdef::env-github,rspecator-view[]

'''
== Implementation Specification
(visible only on this page)

include::../message.adoc[]

include::../highlighting.adoc[]

endif::env-github,rspecator-view[]
