The brief answer to this is simply “yes.” This is why Marbury v. Madison is an important case. It did set a precedent because it was the first time that the Supreme Court ever invalidated a law because it was unconstitutional. However, the case was important for another reason as well.
When the Constitution was written, it did specify that a law that Congress passed was not valid if it was contrary to the Constitution. The problem was that the people who wrote the Constitution neglected to say who got to decide when a law was contrary to the Constitution. It was in Marbury v. Madison that this changed. In that case, the Supreme Court invalidated a law because it was contrary to the Constitution. In doing so, the Court claimed the right to decide which laws were unconstitutional.
Thus, Marbury v. Madison is important for two reasons. First, it was the case in which the Supreme Court claimed the right of judicial review. Second, it was the first time that the Supreme Court actually exercised that power by declaring a law to be unconstitutional.