Fix error that dtrt-indent-diagnosis fails when major-mode is derived.