bhlangonijr / chesslib

chess library for legal move generation, FEN/PGN parsing and more
Apache License 2.0
229 stars 80 forks source link

Reduce the visibility of protected static methods #93

Open alessandrodalbello opened 2 years ago

alessandrodalbello commented 2 years ago

The MoveList implementation contains a couple of protected static methods that depend on the thread-local reference of the board used as a support for the class itself. Honestly, I don't see any reason to expose the internals to sub-classes and other classes in the same package. I believe they could be "safely" converted to private methods and used only internally as support for the MoveList functionalities: existing integrations of the chesslib library should not make any usage of those methods unless they decided to extend MoveList and access statically a method of the super-class. Please, correct me here if there is a motivation to keep the access visibility as it is at the moment.