I don't know of anyone actually doing that, but all the code is right there. You could probably wrangle the linter into checking those things if you really want to. That said, many Ruby frameworks rely on being able to dynamically add methods to classes at runtime so I don't think such a thing would be all that beneficial.
This isn't about coding errors. This is about being able to analyze the code and see if the code is using prohibited methods.
Through static analysis, I can verify if anyone is trying to do something tricky with the String class.
Can I verify if a method is being modified added to an instance of a String in Ruby through static analysis?