| 2215 | // |
| 2216 | |
| 2217 | Map::Pair *Map::FindItem(IntKeyType val, index_t left, index_t right, index_t &insert_pos) |
| 2218 | // left and right must be set by caller to the appropriate bounds within mItem. |
| 2219 | { |
| 2220 | while (left < right) |
| 2221 | { |
| 2222 | index_t mid = left + ((right - left) >> 1); |
| 2223 | auto &item = mItem[mid]; |
| 2224 | |
| 2225 | auto result = val - item.key.i; |
| 2226 | |
| 2227 | if (result < 0) |
| 2228 | right = mid; |
| 2229 | else if (result > 0) |
| 2230 | left = mid + 1; |
| 2231 | else |
| 2232 | return &item; |
| 2233 | } |
| 2234 | insert_pos = left; |
| 2235 | return nullptr; |
| 2236 | } |
| 2237 | |
| 2238 | Object::FieldType *Object::FindField(name_t name, index_t &insert_pos) |
| 2239 | { |
nothing calls this directly
no outgoing calls
no test coverage detected