Error with functions using same name

Saravanan Palanichamy <[email protected]> Sat, 19 Apr 2025 16:02:42 +0530
Newsgroups gmane.comp.lang.groovy.user
Message-ID <CAG3fL7ngJ3QFRvvQ8GL2HQVptEXk+WhqoP=gdCe+3Oh=HGB+0Q@mail.gmail.com>
When I define a class in Groovy with 2 methods with the same name, one
private and one public, I get this error during static compilation

Mixing private and public/protected methods of the same name causes
> multimethods to be disabled and is forbidden to avoid surprising behaviour.
> Renaming the private methods will solve the problem.


I understand the need for multi methods and dispatching with runtime types,
but how can I disable this behaviour? I am using @CompileStatic and it
still hits this error

regards
Saravanan