title: whether io manipulators has to be set for every time in ostringstream?
body: <p>I have the following code</p>
  
  <pre><code>int main()
  {
     std::ostringstream v1,v2;
  
     v1&lt;&lt;setw(5)&lt;&lt;setfill('x')&lt;&lt;5;
     v1&lt;&lt;6;
     std::cout&lt;&lt;"Version 1: "&lt;&lt;v1.str()&lt;&lt;std::endl;
  
     v2&lt;&lt;setw(5)&lt;&lt;setfill('x')&lt;&lt;5;
     v2&lt;&lt;setw(5)&lt;&lt;setfill('x')&lt;&lt;6;
     std::cout&lt;&lt;"Version 2: "&lt;&lt;v2.str()&lt;&lt;std::endl;
  
  
  
     return 0;
  }
  </code></pre>
  
  <p>In version 1, i have set the manipulator first time. But the when printing 6, it was not filled with 'x'.</p>
  
  <p>In version 2, i have set the manipulator both time. But the when printing 6, it was filled with 'x'.</p>
  
  <p>Whether manipulator has to be set every time (or) am i missing anything here?</p>