How to prevent Blender from disabling dyntopo when exiting/entering sculpt mode? This is one of the most annoying things while sculpting with Dyntopo enabled - it switches itself off automatically for various reasons eg. going from sculpt mode into object mode and then back into sculpt mode or undoing too far, to the state of affairs where Dyntopo was disabled.

I had to redo so much sculpting when I realized that nothing suddenly went wrong with my mesh but that I forgot to re-enable Dyntopo that it becomes a major pain. I am aware of the Ctrl + D shortcut to quickly enable Dyntopo, but it just too easy to forget about re-enabling it.

Is there a way to keep Dyntopo enabled by default or prevent it from switching off, maybe at least with some clever Pythong scripting?
This problem has finally been noticed by Blender developers and included in 2.78 release.

"Enable dyntopo re-entering sculpt mode"
https://developer.blender.org/D2059

Dynamic topology will be re-enabled automatically when entering sculpt mode, but only if uv's, vertex colors or triangulating won't be affected.