I bought the 40mm to use on a recently acquired 6D, simply to enable me to carry it, for little more weight than a quality compact. I have not been disappointed for what it is and what it costs its fine, but in my opinion its not as good quality wise as a mk1, much maligned 50mm f1.8. Yes very plastic and cheap looking, but produced some surprisingly good images for such a budget price. I have no experience of the mk 2 version. I like the 40mm, but mainly because my bad back appreciates any grm of weight saved, and its quite quirky to look at!
I had a quick play with the 40stm and thought it a good value lens, at that time I had a 70d in the line up and these two are designed to work together. For video, I'd say it's a bargain, for general landscape and snaps, pretty good value if a bit limiting. I'd suggest get one s/h on eBay and try; if you're not happy you'll get close to your buying price as you sell too.
I use the Canon 100D with 40mm pancake lens as an alternative to a compact camera - so far very pleased with results. I have printed up to A4 so far and very satisfied with results. The 40mm is also good for video on the 100D as it autofocuses almost silently.