What happens if opener bids 3 diamonds (a preemptive bid) and everyone else passes and then it is discovered that opener had 14 points, too many to preempt?
Whatever the result of playing 3D was stands. Bidding incorrectly is not (usually) a violation of the laws of contract bridge.
As @Ruds said, whether you bid 3D on purpose or by accident, you have to play 3D and/or proceed bidding as if 3D is a pre-empt. If the bidding comes back around to opener they are allowed to continue bidding (regularly), indicating that they might not possess a 'standard' preemptive hand; in my experience that only adds to the confusion rather than clearing it up. When in a hole, stop digging.
Two notes I want to make in addition:
- The opener is not allowed to say anything about a bid made in mistake - whether they end up playing 3D, or partner has to play (say, 3 Spades) or opponents play -until that hand is finished.
- If you and/or partner regularly open 7-card hands without regard for points at 3-level, you may need to include that in your bidding system / add that to the system's card:
Opening 3 C/D/H/S: 7 cards, 0-14 HCP
There are no "rules" to bidding. The systems we use now are agreements we make that X bid advertises you have this and that.
By bidding 3D, the opener advertised they do not have opening strength. It is not a crime to mis-advertise your hand (on accident).
You can also mis-advertise your hand on purpose. In that case it's called a psyche. This means that you want to mislead opponents (and your own partner) in the hopes they will miss the right contract or play wrong as declarers. If you psyche too often, that can become a problem though.