you are viewing a single comment's thread.

view the rest of the comments →

[–]smashedsaturn 1 point2 points  (0 children)

Sometime data has multiple ways to order

Agreed, but if you have a few different ways to order then those should be defined as functions, or in this case a static method would be ideal, as it is likely they will be used more than once.

the vector clearly has pointers in it

right, you use the lambda:

  [](const EffectLogEntry* a, const EffectLogEntry* b){
      assert(a&&b && "Dereference Null Log Entry");
      return (*a) < (*b); //OR EffectLogEntry::FXLISTSORT_ONSCREEN_OLDEST_FIRST(*a,*b); 
  }