MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / RM_StringToDouble

Function RM_StringToDouble

src/module.cpp:1396–1399  ·  view source on GitHub ↗

Convert the string into a double, storing it at `*d`. * Returns REDISMODULE_OK on success or REDISMODULE_ERR if the string is * not a valid string representation of a double value. */

Source from the content-addressed store, hash-verified

1394 * Returns REDISMODULE_OK on success or REDISMODULE_ERR if the string is
1395 * not a valid string representation of a double value. */
1396int RM_StringToDouble(const RedisModuleString *str, double *d) {
1397 int retval = getDoubleFromObject(str,d);
1398 return (retval == C_OK) ? REDISMODULE_OK : REDISMODULE_ERR;
1399}
1400
1401/* Convert the string into a long double, storing it at `*ld`.
1402 * Returns REDISMODULE_OK on success or REDISMODULE_ERR if the string is

Callers

nothing calls this directly

Calls 1

getDoubleFromObjectFunction · 0.85

Tested by

no test coverage detected