| 603 | } |
| 604 | |
| 605 | size_t stringObjectLen(robj *o) { |
| 606 | serverAssertWithInfo(NULL,o,o->type == OBJ_STRING); |
| 607 | if (sdsEncodedObject(o)) { |
| 608 | return sdslen(o->ptr); |
| 609 | } else { |
| 610 | return sdigits10((long)o->ptr); |
| 611 | } |
| 612 | } |
| 613 | |
| 614 | int getDoubleFromObject(const robj *o, double *target) { |
| 615 | double value; |
no test coverage detected