Does this wiring meet the NEC standards?
The answer is No. brhans, guess is correct. Many water heaters are wired this way because there are no neutral's in a standard 240V water heater. The white wire needs at least 6" of other than white or green identification some inspectors want everything in the box identified (taped or painted). Black is the most common color using tape but, it can be painted also I found red fingernail polish and this is totally legal also. Added for history: The oldest code book I have handy is NEC 2002. Section 200.6 &amp; 200.7 both identify the grounding conductor as white / gray or white / gray stripe along entire length.
310.12.C states ungrounded conductors shall be finished to be clearly distinguishable from grounded and grounding conductors. So this has been code for quite some time.