That's the thing, ain't it? If you exit the market for cash during an inflation period you will realize losses of x% per annum. So the question is: Is the current stock bubble driven by inflation expectations?
Whatever the current perceived cause, if we do see massive inflation then it's not a bubble.