Check out the Pastebin Gadgets Shop. We have thousands of fun, geeky & affordable gadgets on sale :-)Want more features on Pastebin? Sign Up, it's FREE!

for_each on a COM IEnumXxx interface

By: a guest on Feb 26th, 2012  |  syntax: None  |  size: 0.14 KB  |  views: 19  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print  |  QR code  |  clone
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. IEnumUnkPtr pEnumUnk;
  2. // ...something that fills in pEnumUnk...
  3. MagicThing m(pEnumUnk);
  4. std::for_each(m.begin(), m.end(), DoSomethingWithUnk);
clone this paste RAW Paste Data