binary '<' : no operator found for map<std::string, shared_ptr<Foo>>
<p>How can I resolve the following compiler error:</p>

<pre><code>xstddef(180): error C2678: binary '&lt;' : no operator found which takes a left-hand operand of type 'const std::string' (or there is no acceptable conversion)
          tuple(572): could be 'bool std::operator &lt;(const std::tuple&lt;&gt; &amp;,const std::tuple&lt;&gt; &amp;)'
          while trying to match the argument list '(const std::string, const std::string)'
          xstddef(179) : while compiling class template member function 'bool std::less&lt;_Ty&gt;::operator ()(const _Ty &amp;,const _Ty &amp;) const'
          with
          [
              _Ty=std::string
          ]
          map(177) : see reference to function template instantiation 'bool std::less&lt;_Ty&gt;::operator ()(const _Ty &amp;,const _Ty &amp;) const' being compiled
          with
          [
              _Ty=std::string
          ]
          type_traits(743) : see reference to class template instantiation 'std::less&lt;_Ty&gt;' being compiled
          with
          [
              _Ty=std::string
          ]
          xtree(1028) : see reference to class template instantiation 'std::is_empty&lt;_Ty&gt;' being compiled
          with
          [
              _Ty=std::less&lt;std::string&gt;
          ]
          map(67) : see reference to class template instantiation 'std::_Tree&lt;_Traits&gt;' being compiled
          with
          [
              _Traits=std::_Tmap_traits&lt;std::string,IDispatcherPtr,std::less&lt;std::string&gt;,std::allocator&lt;std::pair&lt;const std::string,IDispatcherPtr&gt;&gt;,false&gt;
          ]
          main.cpp(506) : see reference to class template instantiation 'std::map&lt;_Kty,_Ty&gt;' being compiled
          with
          [
              _Kty=std::string,
              _Ty=IDispatcherPtr
          ]
</code></pre>

<p>for the following code:</p>

<pre><code>class IDispatcher
{
    virtual void operator()() = 0;
};

class AlarmDispatcher: public IDispatcher
{
    virtual void operator()()
    {
    }
};

typedef boost::shared_ptr&lt;IDispatcher&gt; IDispatcherPtr;

int main()
{
    std::map&lt;std::string, IDispatcherPtr&gt; dispatchers;
    dispatchers["alarm"] = boost::make_shared&lt;AlarmDispatcher&gt;();
</code></pre>
