亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? printf.c

?? sqlite庫
?? C
?? 第 1 頁 / 共 2 頁
字號:
/*** The "printf" code that follows dates from the 1980's.  It is in** the public domain.  The original comments are included here for** completeness.  They are very out-of-date but might be useful as** an historical reference.  Most of the "enhancements" have been backed** out so that the functionality is now the same as standard printf().******************************************************************************** The following modules is an enhanced replacement for the "printf" subroutines** found in the standard C library.  The following enhancements are** supported:****      +  Additional functions.  The standard set of "printf" functions**         includes printf, fprintf, sprintf, vprintf, vfprintf, and**         vsprintf.  This module adds the following:****           *  snprintf -- Works like sprintf, but has an extra argument**                          which is the size of the buffer written to.****           *  mprintf --  Similar to sprintf.  Writes output to memory**                          obtained from malloc.****           *  xprintf --  Calls a function to dispose of output.****           *  nprintf --  No output, but returns the number of characters**                          that would have been output by printf.****           *  A v- version (ex: vsnprintf) of every function is also**              supplied.****      +  A few extensions to the formatting notation are supported:****           *  The "=" flag (similar to "-") causes the output to be**              be centered in the appropriately sized field.****           *  The %b field outputs an integer in binary notation.****           *  The %c field now accepts a precision.  The character output**              is repeated by the number of times the precision specifies.****           *  The %' field works like %c, but takes as its character the**              next character of the format string, instead of the next**              argument.  For example,  printf("%.78'-")  prints 78 minus**              signs, the same as  printf("%.78c",'-').****      +  When compiled using GCC on a SPARC, this version of printf is**         faster than the library printf for SUN OS 4.1.****      +  All functions are fully reentrant.***/#include "sqliteInt.h"/*** Conversion types fall into various categories as defined by the** following enumeration.*/#define etRADIX       1 /* Integer types.  %d, %x, %o, and so forth */#define etFLOAT       2 /* Floating point.  %f */#define etEXP         3 /* Exponentional notation. %e and %E */#define etGENERIC     4 /* Floating or exponential, depending on exponent. %g */#define etSIZE        5 /* Return number of characters processed so far. %n */#define etSTRING      6 /* Strings. %s */#define etDYNSTRING   7 /* Dynamically allocated strings. %z */#define etPERCENT     8 /* Percent symbol. %% */#define etCHARX       9 /* Characters. %c *//* The rest are extensions, not normally found in printf() */#define etCHARLIT    10 /* Literal characters.  %' */#define etSQLESCAPE  11 /* Strings with '\'' doubled.  %q */#define etSQLESCAPE2 12 /* Strings with '\'' doubled and enclosed in '',                          NULL pointers replaced by SQL NULL.  %Q */#define etTOKEN      13 /* a pointer to a Token structure */#define etSRCLIST    14 /* a pointer to a SrcList */#define etPOINTER    15 /* The %p conversion *//*** An "etByte" is an 8-bit unsigned value.*/typedef unsigned char etByte;/*** Each builtin conversion character (ex: the 'd' in "%d") is described** by an instance of the following structure*/typedef struct et_info {   /* Information about each format field */  char fmttype;            /* The format field code letter */  etByte base;             /* The base for radix conversion */  etByte flags;            /* One or more of FLAG_ constants below */  etByte type;             /* Conversion paradigm */  etByte charset;          /* Offset into aDigits[] of the digits string */  etByte prefix;           /* Offset into aPrefix[] of the prefix string */} et_info;/*** Allowed values for et_info.flags*/#define FLAG_SIGNED  1     /* True if the value to convert is signed */#define FLAG_INTERN  2     /* True if for internal use only */#define FLAG_STRING  4     /* Allow infinity precision *//*** The following table is searched linearly, so it is good to put the** most frequently used conversion types first.*/static const char aDigits[] = "0123456789ABCDEF0123456789abcdef";static const char aPrefix[] = "-x0\000X0";static const et_info fmtinfo[] = {  {  'd', 10, 1, etRADIX,      0,  0 },  {  's',  0, 4, etSTRING,     0,  0 },  {  'g',  0, 1, etGENERIC,    30, 0 },  {  'z',  0, 6, etDYNSTRING,  0,  0 },  {  'q',  0, 4, etSQLESCAPE,  0,  0 },  {  'Q',  0, 4, etSQLESCAPE2, 0,  0 },  {  'c',  0, 0, etCHARX,      0,  0 },  {  'o',  8, 0, etRADIX,      0,  2 },  {  'u', 10, 0, etRADIX,      0,  0 },  {  'x', 16, 0, etRADIX,      16, 1 },  {  'X', 16, 0, etRADIX,      0,  4 },#ifndef SQLITE_OMIT_FLOATING_POINT  {  'f',  0, 1, etFLOAT,      0,  0 },  {  'e',  0, 1, etEXP,        30, 0 },  {  'E',  0, 1, etEXP,        14, 0 },  {  'G',  0, 1, etGENERIC,    14, 0 },#endif  {  'i', 10, 1, etRADIX,      0,  0 },  {  'n',  0, 0, etSIZE,       0,  0 },  {  '%',  0, 0, etPERCENT,    0,  0 },  {  'p', 16, 0, etPOINTER,    0,  1 },  {  'T',  0, 2, etTOKEN,      0,  0 },  {  'S',  0, 2, etSRCLIST,    0,  0 },};#define etNINFO  (sizeof(fmtinfo)/sizeof(fmtinfo[0]))/*** If SQLITE_OMIT_FLOATING_POINT is defined, then none of the floating point** conversions will work.*/#ifndef SQLITE_OMIT_FLOATING_POINT/*** "*val" is a double such that 0.1 <= *val < 10.0** Return the ascii code for the leading digit of *val, then** multiply "*val" by 10.0 to renormalize.**** Example:**     input:     *val = 3.14159**     output:    *val = 1.4159    function return = '3'**** The counter *cnt is incremented each time.  After counter exceeds** 16 (the number of significant digits in a 64-bit float) '0' is** always returned.*/static int et_getdigit(LONGDOUBLE_TYPE *val, int *cnt){  int digit;  LONGDOUBLE_TYPE d;  if( (*cnt)++ >= 16 ) return '0';  digit = (int)*val;  d = digit;  digit += '0';  *val = (*val - d)*10.0;  return digit;}#endif /* SQLITE_OMIT_FLOATING_POINT *//*** On machines with a small stack size, you can redefine the** SQLITE_PRINT_BUF_SIZE to be less than 350.  But beware - for** smaller values some %f conversions may go into an infinite loop.*/#ifndef SQLITE_PRINT_BUF_SIZE# define SQLITE_PRINT_BUF_SIZE 350#endif#define etBUFSIZE SQLITE_PRINT_BUF_SIZE  /* Size of the output buffer *//*** The root program.  All variations call this core.**** INPUTS:**   func   This is a pointer to a function taking three arguments**            1. A pointer to anything.  Same as the "arg" parameter.**            2. A pointer to the list of characters to be output**               (Note, this list is NOT null terminated.)**            3. An integer number of characters to be output.**               (Note: This number might be zero.)****   arg    This is the pointer to anything which will be passed as the**          first argument to "func".  Use it for whatever you like.****   fmt    This is the format string, as in the usual print.****   ap     This is a pointer to a list of arguments.  Same as in**          vfprint.**** OUTPUTS:**          The return value is the total number of characters sent to**          the function "func".  Returns -1 on a error.**** Note that the order in which automatic variables are declared below** seems to make a big difference in determining how fast this beast** will run.*/static int vxprintf(  void (*func)(void*,const char*,int),     /* Consumer of text */  void *arg,                         /* First argument to the consumer */  int useExtended,                   /* Allow extended %-conversions */  const char *fmt,                   /* Format string */  va_list ap                         /* arguments */){  int c;                     /* Next character in the format string */  char *bufpt;               /* Pointer to the conversion buffer */  int precision;             /* Precision of the current field */  int length;                /* Length of the field */  int idx;                   /* A general purpose loop counter */  int count;                 /* Total number of characters output */  int width;                 /* Width of the current field */  etByte flag_leftjustify;   /* True if "-" flag is present */  etByte flag_plussign;      /* True if "+" flag is present */  etByte flag_blanksign;     /* True if " " flag is present */  etByte flag_alternateform; /* True if "#" flag is present */  etByte flag_altform2;      /* True if "!" flag is present */  etByte flag_zeropad;       /* True if field width constant starts with zero */  etByte flag_long;          /* True if "l" flag is present */  etByte flag_longlong;      /* True if the "ll" flag is present */  etByte done;               /* Loop termination flag */  sqlite_uint64 longvalue;   /* Value for integer types */  LONGDOUBLE_TYPE realvalue; /* Value for real types */  const et_info *infop;      /* Pointer to the appropriate info structure */  char buf[etBUFSIZE];       /* Conversion buffer */  char prefix;               /* Prefix character.  "+" or "-" or " " or '\0'. */  etByte errorflag = 0;      /* True if an error is encountered */  etByte xtype;              /* Conversion paradigm */  char *zExtra;              /* Extra memory used for etTCLESCAPE conversions */  static const char spaces[] =   "                                                                         ";#define etSPACESIZE (sizeof(spaces)-1)#ifndef SQLITE_OMIT_FLOATING_POINT  int  exp, e2;              /* exponent of real numbers */  double rounder;            /* Used for rounding floating point values */  etByte flag_dp;            /* True if decimal point should be shown */  etByte flag_rtz;           /* True if trailing zeros should be removed */  etByte flag_exp;           /* True to force display of the exponent */  int nsd;                   /* Number of significant digits returned */#endif  func(arg,"",0);  count = length = 0;  bufpt = 0;  for(; (c=(*fmt))!=0; ++fmt){    if( c!='%' ){      int amt;      bufpt = (char *)fmt;      amt = 1;      while( (c=(*++fmt))!='%' && c!=0 ) amt++;      (*func)(arg,bufpt,amt);      count += amt;      if( c==0 ) break;    }    if( (c=(*++fmt))==0 ){      errorflag = 1;      (*func)(arg,"%",1);      count++;      break;    }    /* Find out what flags are present */    flag_leftjustify = flag_plussign = flag_blanksign =      flag_alternateform = flag_altform2 = flag_zeropad = 0;    done = 0;    do{      switch( c ){        case '-':   flag_leftjustify = 1;     break;        case '+':   flag_plussign = 1;        break;        case ' ':   flag_blanksign = 1;       break;        case '#':   flag_alternateform = 1;   break;        case '!':   flag_altform2 = 1;        break;        case '0':   flag_zeropad = 1;         break;        default:    done = 1;                 break;      }    }while( !done && (c=(*++fmt))!=0 );    /* Get the field width */    width = 0;    if( c=='*' ){      width = va_arg(ap,int);      if( width<0 ){        flag_leftjustify = 1;        width = -width;      }      c = *++fmt;    }else{      while( c>='0' && c<='9' ){        width = width*10 + c - '0';        c = *++fmt;      }    }    if( width > etBUFSIZE-10 ){      width = etBUFSIZE-10;    }    /* Get the precision */    if( c=='.' ){      precision = 0;      c = *++fmt;      if( c=='*' ){        precision = va_arg(ap,int);        if( precision<0 ) precision = -precision;        c = *++fmt;      }else{        while( c>='0' && c<='9' ){          precision = precision*10 + c - '0';          c = *++fmt;        }      }    }else{      precision = -1;    }    /* Get the conversion type modifier */    if( c=='l' ){      flag_long = 1;      c = *++fmt;      if( c=='l' ){        flag_longlong = 1;        c = *++fmt;      }else{        flag_longlong = 0;      }    }else{      flag_long = flag_longlong = 0;    }    /* Fetch the info entry for the field */    infop = 0;    for(idx=0; idx<etNINFO; idx++){      if( c==fmtinfo[idx].fmttype ){        infop = &fmtinfo[idx];        if( useExtended || (infop->flags & FLAG_INTERN)==0 ){          xtype = infop->type;        }        break;      }    }    zExtra = 0;    if( infop==0 ){      return -1;    }    /* Limit the precision to prevent overflowing buf[] during conversion */    if( precision>etBUFSIZE-40 && (infop->flags & FLAG_STRING)==0 ){      precision = etBUFSIZE-40;    }    /*    ** At this point, variables are initialized as follows:    **    **   flag_alternateform          TRUE if a '#' is present.    **   flag_altform2               TRUE if a '!' is present.    **   flag_plussign               TRUE if a '+' is present.    **   flag_leftjustify            TRUE if a '-' is present or if the    **                               field width was negative.    **   flag_zeropad                TRUE if the width began with 0.    **   flag_long                   TRUE if the letter 'l' (ell) prefixed    **                               the conversion character.    **   flag_longlong               TRUE if the letter 'll' (ell ell) prefixed    **                               the conversion character.    **   flag_blanksign              TRUE if a ' ' is present.    **   width                       The specified field width.  This is    **                               always non-negative.  Zero is the default.    **   precision                   The specified precision.  The default    **                               is -1.    **   xtype                       The class of the conversion.    **   infop                       Pointer to the appropriate info struct.    */    switch( xtype ){      case etPOINTER:        flag_longlong = sizeof(char*)==sizeof(i64);        flag_long = sizeof(char*)==sizeof(long int);        /* Fall through into the next case */      case etRADIX:        if( infop->flags & FLAG_SIGNED ){          i64 v;          if( flag_longlong )   v = va_arg(ap,i64);          else if( flag_long )  v = va_arg(ap,long int);          else                  v = va_arg(ap,int);          if( v<0 ){            longvalue = -v;            prefix = '-';          }else{            longvalue = v;            if( flag_plussign )        prefix = '+';            else if( flag_blanksign )  prefix = ' ';            else                       prefix = 0;          }        }else{          if( flag_longlong )   longvalue = va_arg(ap,u64);          else if( flag_long )  longvalue = va_arg(ap,unsigned long int);          else                  longvalue = va_arg(ap,unsigned int);          prefix = 0;        }        if( longvalue==0 ) flag_alternateform = 0;        if( flag_zeropad && precision<width-(prefix!=0) ){          precision = width-(prefix!=0);        }        bufpt = &buf[etBUFSIZE-1];        {          register const char *cset;      /* Use registers for speed */          register int base;          cset = &aDigits[infop->charset];          base = infop->base;          do{                                           /* Convert to ascii */            *(--bufpt) = cset[longvalue%base];            longvalue = longvalue/base;          }while( longvalue>0 );        }        length = &buf[etBUFSIZE-1]-bufpt;        for(idx=precision-length; idx>0; idx--){          *(--bufpt) = '0';                             /* Zero pad */        }        if( prefix ) *(--bufpt) = prefix;               /* Add sign */        if( flag_alternateform && infop->prefix ){      /* Add "0" or "0x" */          const char *pre;          char x;          pre = &aPrefix[infop->prefix];          if( *bufpt!=pre[0] ){            for(; (x=(*pre))!=0; pre++) *(--bufpt) = x;          }        }        length = &buf[etBUFSIZE-1]-bufpt;        break;      case etFLOAT:      case etEXP:      case etGENERIC:        realvalue = va_arg(ap,double);#ifndef SQLITE_OMIT_FLOATING_POINT

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲一区在线电影| 中文字幕视频一区二区三区久| 国产suv精品一区二区三区| 亚洲精品自拍动漫在线| 久久久久久一二三区| 欧美精品日韩一本| 懂色中文一区二区在线播放| 蜜臀av亚洲一区中文字幕| 亚洲人精品一区| 国产婷婷精品av在线| 日韩一区二区三区av| 在线观看免费亚洲| 成人禁用看黄a在线| 国产一区二区电影| 免费看日韩a级影片| 亚洲一区在线观看免费观看电影高清| 国产女人水真多18毛片18精品视频| 日韩一区二区在线看| 欧美人妖巨大在线| 欧美综合一区二区| 91亚洲精品久久久蜜桃| 成人小视频免费在线观看| 国产一区视频网站| 国产一区二区在线电影| 久草中文综合在线| 久久国产精品一区二区| 日韩国产欧美三级| 亚洲chinese男男1069| 亚洲福利视频导航| 亚洲福利一区二区| 婷婷中文字幕综合| 亚洲国产欧美日韩另类综合| 亚洲最新在线观看| 亚洲制服丝袜一区| 亚洲国产一区二区三区| 亚洲国产成人av| 日韩精品久久理论片| 秋霞电影网一区二区| 蜜桃av一区二区| 狠狠色综合播放一区二区| 国产一区中文字幕| 国产成人自拍在线| 成人免费毛片片v| 99久久精品国产导航| 色婷婷av一区二区三区软件| 欧美影院一区二区| 91精品国产综合久久久久久久 | 久久av老司机精品网站导航| 日韩1区2区日韩1区2区| 蜜臀av性久久久久蜜臀aⅴ流畅 | 捆绑调教一区二区三区| 精品综合久久久久久8888| 国产在线精品一区二区不卡了| 国产成人免费在线| 成人av动漫网站| 欧美日韩中文国产| 91精品久久久久久久91蜜桃| 精品国产人成亚洲区| 国产亚洲综合av| 亚洲欧洲精品一区二区精品久久久| 亚洲人快播电影网| 三级一区在线视频先锋 | www国产成人| 国产精品久久久久四虎| 亚洲线精品一区二区三区八戒| 日韩激情视频网站| 国产精品夜夜爽| 91美女精品福利| 制服丝袜av成人在线看| 久久精品人人做| 亚洲精品高清视频在线观看| 男女男精品视频网| 成人免费视频一区| 欧美高清视频www夜色资源网| 精品国产一区二区精华| 亚洲免费毛片网站| 蜜桃视频第一区免费观看| 成人动漫视频在线| 在线播放一区二区三区| 国产亚洲精品超碰| 午夜不卡av免费| 成人黄色小视频在线观看| 欧美日韩国产欧美日美国产精品| 久久久久久久久岛国免费| 亚洲蜜臀av乱码久久精品| 久草热8精品视频在线观看| 色欧美乱欧美15图片| 日韩免费看的电影| 夜夜精品浪潮av一区二区三区| 国内成+人亚洲+欧美+综合在线| 色婷婷av一区| 欧美国产视频在线| 麻豆传媒一区二区三区| 在线免费视频一区二区| 欧美韩国一区二区| 免费观看91视频大全| 欧美体内she精高潮| 国产拍揄自揄精品视频麻豆| 日韩av网站在线观看| 91麻豆文化传媒在线观看| 久久久噜噜噜久久中文字幕色伊伊 | 蜜臀av一区二区三区| 色av一区二区| 国产精品进线69影院| 国产一区中文字幕| 日韩欧美资源站| 亚洲高清一区二区三区| 99综合电影在线视频| 久久久久久夜精品精品免费| 美腿丝袜在线亚洲一区| 欧美日韩日本视频| 亚洲免费观看在线观看| 成人黄色大片在线观看| 久久九九久精品国产免费直播| 美女脱光内衣内裤视频久久影院| 欧美在线综合视频| 亚洲欧洲成人自拍| 粉嫩蜜臀av国产精品网站| 精品卡一卡二卡三卡四在线| 强制捆绑调教一区二区| 欧美精品日韩精品| 视频一区二区欧美| 在线免费观看日韩欧美| 亚洲制服丝袜在线| 欧美色欧美亚洲另类二区| 亚洲综合成人在线视频| 色94色欧美sute亚洲线路二| 亚洲色图都市小说| 99riav久久精品riav| 国产精品国产成人国产三级| 国产精品亚洲综合一区在线观看| 久久久久国产精品厨房| 国产福利一区二区三区| 中日韩免费视频中文字幕| 福利视频网站一区二区三区| 国产精品免费av| 95精品视频在线| 亚洲色图清纯唯美| 欧美亚洲一区二区在线| 亚洲高清不卡在线观看| 欧美老年两性高潮| 日韩电影在线免费观看| 日韩视频在线永久播放| 久久99精品久久久久久国产越南 | 精品国产三级a在线观看| 精品一区二区三区视频在线观看| 欧美大片免费久久精品三p| 狠狠色丁香婷综合久久| 国产女人18水真多18精品一级做| 国产麻豆欧美日韩一区| 国产日韩欧美高清| 99久精品国产| 亚洲高清不卡在线观看| 91精品国产麻豆国产自产在线| 蜜臀av性久久久久蜜臀av麻豆| 久久综合久久久久88| 成人在线综合网| 一区二区三区在线看| 91精品黄色片免费大全| 国产一区三区三区| 亚洲美女一区二区三区| 精品婷婷伊人一区三区三| 另类成人小视频在线| 中文字幕巨乱亚洲| 欧美又粗又大又爽| 蜜桃视频一区二区三区 | 亚洲国产经典视频| 在线看不卡av| 蜜臀国产一区二区三区在线播放| 久久久99精品免费观看| 91免费看视频| 开心九九激情九九欧美日韩精美视频电影| 久久久精品国产免大香伊| 91亚洲精品久久久蜜桃网站 | 亚洲色欲色欲www| 在线播放中文一区| 成人在线一区二区三区| 亚洲第一av色| 久久久99免费| 欧美三区在线视频| 国产精品系列在线播放| 亚洲午夜久久久久久久久电影院 | 国产精品日韩成人| 欧美一级午夜免费电影| 国产精华液一区二区三区| 夜夜爽夜夜爽精品视频| 2020日本不卡一区二区视频| 色综合久久久久综合体| 国产麻豆精品一区二区| 亚洲一区二区三区小说| 欧美极品美女视频| 欧美一区二区久久久| 91小视频在线| 狠狠色丁香久久婷婷综合_中| 亚洲最色的网站| 国产喷白浆一区二区三区| 欧美一区二区三区在线电影| 一本色道久久加勒比精品| 国产一区二区三区免费在线观看 | 日韩精彩视频在线观看|