title: priority_queue's emplace and push
body: <p>I noticed in some code. They uses <code>emplace</code> instead of '<code>push'</code>  even the element they insert is actually that instance.</p>
  
  <p>For example.</p>
  
  <pre><code>class Star {
   public:
    // The distance between this star to the Earth.
    double distance() const { return sqrt(x_ * x_ + y_ * y_ + z_ * z_); }
  
    bool operator&lt;(const Star&amp; s) const { return distance() &lt; s.distance(); }
  
    int ID_;
    double x_, y_, z_; 
  };
  
  vector&lt;Star&gt; find_closest_k_stars(int k, istringstream *sin) {
    // Use max_heap to find the closest k stars.
    priority_queue&lt;Star&gt; max_heap;
    string line;
  
    // Record the first k stars.
    while (getline(*sin, line)) {
      stringstream line_stream(line);
      string buf;
      getline(line_stream, buf, ',');
      int ID = stoi(buf);
      array&lt;double, 3&gt; data;  // stores x, y, and z.
      for (int i = 0; i &lt; 3; ++i) {
        getline(line_stream, buf, ',');
        data[i] = stod(buf);
      }   
      Star s{ID, data[0], data[1], data[2]};
  
      if (max_heap.size() == k) {
        // Compare the top of heap with the incoming star.
        Star far_star = max_heap.top();
        if (s &lt; far_star) {
          max_heap.pop();
          max_heap.emplace(s);
        }   
      } else {
        max_heap.emplace(s);  //I think here we  can use push instead of emplace, right?
      }   
    }
  </code></pre>
  
  <p>in code :max_heap.emplace(s);  //I think here we  can use push instead of emplace, right?</p>