Agree with Ed. I was using the 50mm for awhile till the 40mm was launched. Ever since then, 40mm is with me as my walk about lens, even on film body. Love the colors on the STM. I'm not into Bokeh...so personal preference. If you are into Bokeh, then either the sigma or canon 50 f/1.4. Can Consider the Sigma 30 as well.
i have used all three, and i'd say the 40mm f2.8 and the 50mm f1.4 are both good lenses. While i use the 40mm more often now, i still keep my 50mm instead of selling it.