I know there is some debate on whether legal reasoning should be subject matter for this site; however, when responding to what a court can do, it depends on the legal system of that country. Legal systems, in general, can be broken up into two main categories, common law and civil law countries.
Should there be tags to make this distinction? It might help people trying to find an answer on reasoning and the impact of prior cases on future cases.