Lines Matching refs:zNum

22685 ** Compare the 19-character string zNum against the text representation
22687 ** if zNum is less than, equal to, or greater than the string.
22688 ** Note that zNum must contain exactly 19 characters.
22698 static int compare2pow63(const char *zNum, int incr){
22704 c = (zNum[i*incr]-pow63[i])*10;
22707 c = zNum[18*incr] - '8';
22716 ** Convert zNum to a 64-bit signed integer. zNum must be decimal. This
22719 ** If the zNum value is representable as a 64-bit twos-complement
22722 ** If zNum is exactly 9223372036854775808, return 2. This special
22726 ** If zNum is too big for a 64-bit integer and is not
22727 ** 9223372036854775808 or if zNum contains any non-numeric text,
22734 SQLITE_PRIVATE int sqlite3Atoi64(const char *zNum, i64 *pNum, int length, u8 enc){
22742 const char *zEnd = zNum + length;
22749 for(i=3-enc; i<length && zNum[i]==0; i+=2){}
22751 zEnd = zNum+i+enc-3;
22752 zNum += (enc&1);
22754 while( zNum<zEnd && sqlite3Isspace(*zNum) ) zNum+=incr;
22755 if( zNum<zEnd ){
22756 if( *zNum=='-' ){
22758 zNum+=incr;
22759 }else if( *zNum=='+' ){
22760 zNum+=incr;
22763 zStart = zNum;
22764 while( zNum<zEnd && zNum[0]=='0' ){ zNum+=incr; } /* Skip leading zeros. */
22765 for(i=0; &zNum[i]<zEnd && (c=zNum[i])>='0' && c<='9'; i+=incr){
22778 if( (c!=0 && &zNum[i]<zEnd) || (i==0 && zStart==zNum) || i>19*incr || nonNum ){
22779 /* zNum is empty or contains non-numeric text or is longer
22787 /* zNum is a 19-digit numbers. Compare it against 9223372036854775808. */
22788 c = compare2pow63(zNum, incr);
22790 /* zNum is less than 9223372036854775808 so it fits */
22794 /* zNum is greater than 9223372036854775808 so it overflows */
22797 /* zNum is exactly 9223372036854775808. Fits if negative. The
22838 ** If zNum represents an integer that will fit in 32-bits, then set
22843 ** Any non-numeric characters that following zNum are ignored.
22847 SQLITE_PRIVATE int sqlite3GetInt32(const char *zNum, int *pValue){
22851 if( zNum[0]=='-' ){
22853 zNum++;
22854 }else if( zNum[0]=='+' ){
22855 zNum++;
22858 else if( zNum[0]=='0'
22859 && (zNum[1]=='x' || zNum[1]=='X')
22860 && sqlite3Isxdigit(zNum[2])
22863 zNum += 2;
22864 while( zNum[0]=='0' ) zNum++;
22865 for(i=0; sqlite3Isxdigit(zNum[i]) && i<8; i++){
22866 u = u*16 + sqlite3HexToInt(zNum[i]);
22868 if( (u&0x80000000)==0 && sqlite3Isxdigit(zNum[i])==0 ){
22876 for(i=0; i<11 && (c = zNum[i] - '0')>=0 && c<=9; i++){