| 895 | } |
| 896 | |
| 897 | void sort(SorterFunc inSorter) |
| 898 | { |
| 899 | if ( (int)hx::ArrayTraits<ELEM_>::StoreType==(int)hx::arrayObject || |
| 900 | (int)hx::ArrayTraits<ELEM_>::StoreType==(int)hx::arrayString) |
| 901 | { |
| 902 | // Keep references from being hidden inside sorters buffers |
| 903 | safeSort(inSorter, (int)hx::ArrayTraits<ELEM_>::StoreType==(int)hx::arrayString); |
| 904 | } |
| 905 | else |
| 906 | { |
| 907 | ELEM_ *e = (ELEM_ *)mBase; |
| 908 | std::stable_sort(e, e+length, Sorter(inSorter) ); |
| 909 | } |
| 910 | } |
| 911 | |
| 912 | Dynamic iterator() { return new hx::ArrayIterator<ELEM_,ELEM_>(this); } |
| 913 | Dynamic keyValueIterator() { return new hx::ArrayKeyValueIterator<ELEM_,ELEM_>(this); } |
no test coverage detected