title: Entering a minor mode with a major mode in Emacs
body: <p>This question may be a duplicate of <a href="https://stackoverflow.com/questions/4253473/emacs-how-do-i-automatically-enter-minor-modes-when-i-enter-a-major-mode">this question</a>, but I can't get the following to work properly in my emacs.</p>
  
  <p>I am trying to enter minor mode <code>mlint-mode</code> whenever I enter major mode <code>matlab-mode</code> (both modes available at <a href="http://matlab-emacs.cvs.sourceforge.net/viewvc/matlab-emacs/matlab-emacs/" rel="nofollow noreferrer">their SourceForge page</a>). I have the following in my .emacs file:</p>
  
  <pre><code>(add-hook 'matlab-mode-hook
        (function (lambda()
                    (mlint-mode))))
  </code></pre>
  
  <p>which looks like the answer to the question I linked above. When opening a <code>.m</code> file, I get the following error:</p>
  
  <blockquote>
    <p>File mode specification error: (void-function mlint-mode)</p>
  </blockquote>
  
  <p>Could someone please assist in helping me write the correct hook to enter <code>mlint-mode</code> when I open a <code>.m</code> file? FWIW, I'm running emacs 23.1.50.1.</p>