📄 vsprintf.c
字号:
/* - VSPRINTF.C -
The ANSI "vsprintf" function.
$Revision: 1.3 $
Copyright 1986 - 1999 IAR Systems. All rights reserved.
*/
#include "stdarg.h"
#include "stdio.h"
#include "icclbutl.h"
static void put_c_in_string(char c, void *ptr) /* Low-level output */
{
*(*(char **) ptr)++ = c;
}
int vsprintf(char *s, const char *format, va_list ap)
{
int nr_of_chars;
nr_of_chars = _formatted_write(format, put_c_in_string, (void *) &s, ap);
*s = '\0'; /* String should be terminated with NUL */
return nr_of_chars; /* According to ANSI */
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -