Hiding things is totally great in crypto code! When I’m implementing signature verification, I shouldn’t have to worry how the underlying, eg, field or elliptic curve algebra is implemented!
In fact there have been many crypto bugs which insufficiently abstract this kind of stuff away.