MCPcopy Create free account
hub / github.com/RcppCore/Rcpp / getoffset

Function getoffset

src/date.cpp:520–534  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

518 }
519
520 static const char * getoffset(const char *strp, int_fast32_t *const offsetp) {
521 int neg = 0;
522
523 if (*strp == '-') {
524 neg = 1;
525 ++strp;
526 } else if (*strp == '+')
527 ++strp;
528 strp = getsecs(strp, offsetp);
529 if (strp == NULL)
530 return NULL; /* illegal time */
531 if (neg)
532 *offsetp = -*offsetp;
533 return strp;
534 }
535
536 static const char * getsecs(const char *strp, int_fast32_t *const secsp) {
537 int num;

Callers 1

tzparseFunction · 0.85

Calls 1

getsecsFunction · 0.85

Tested by

no test coverage detected