title: Passing template classes as arguments
body: <p>I have two template classes FibonacciHeap and Adapter. Both of them have the same interface.</p>
  
  <pre><code>template&lt; typename PRIO, typename VALUE, typename CMP = std::less&lt;PRIO&gt; &gt;
  class FibonacciHeap;
  
  template&lt;typename PRIO,typename VALUE &gt;
  class BinaryHeap;
  </code></pre>
  
  <p>I have another function <code>dijkstra</code>. It can use either <code>BinaryHeap&lt;double,int&gt;</code> or <code>FibonacciHeap&lt;double,int&gt;</code> as its priority queue. I want to pass the type of priority queue as argument. </p>
  
  <p>How can I do that? I know writing an abstract class is an option, but I don't really want to do that. I am looking for other options.</p>