The judge will sh!t all over that "defense." If he gets a lawyer to spout this defense, he might not get laughed out of the courtroom.
Thing is, the courtroom is not the appropriate place to attack the legality of the judge's position. That's something that needs to be taken up in the state legislature or challenged in a separate lawsuit.