fix nesting issues in ido-mode declaration