I didn't mention anything about the stock market. I said if you can invest somewhere with a return greater than 3.5% after tax.
Implicit in that was that the investment is risk-free i.e. it's a government bond or something. But it could be a risky investment, if the risk-return trade-off is high enough.
If I had the opportunity to invest at a 10% rate of return with a stdev of 5% then absolutely, I'd remortgage my house at 4% to do that!