Public companies are trying to box out specific areas where they might legally do that: C-corps, mission-based exemptions during public sale, etc
But—and this is full on opinion now—I suspect when the chips are down, the courts will rule that Google can't just burn a pile of value because "we like Science" or somesuch thing. They'll get away with it as long as the pile of money is growing. And hopefully that's "forever". But maybe forever isn't as long as we think it is. The world is changing. Snapchat cometh.
That's when stockholders file lawsuits alleging violation of director fiduciary responsibility. This can happen with a startup if the management proposes a funding round that's a significant lose for existing shareholders. The directors have the obligation to act in the best interest of the stockholders, not the management.
It also comes up when a company has assets and is losing money, and the stockholders want to liquidate and get some money out, while management wants to burn all the cash out to the bitter end.