⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 stdlib.c

📁 linux 内核源代码
💻 C
字号:
/* * stdlib functions * * Author: Scott Wood <scottwood@freescale.com> * * Copyright (c) 2007 Freescale Semiconductor, Inc. * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. */#include "stdlib.h"/* Not currently supported: leading whitespace, sign, 0x prefix, zero base */unsigned long long int strtoull(const char *ptr, char **end, int base){	unsigned long long ret = 0;	if (base > 36)		goto out;	while (*ptr) {		int digit;		if (*ptr >= '0' && *ptr <= '9' && *ptr < '0' + base)			digit = *ptr - '0';		else if (*ptr >= 'A' && *ptr < 'A' + base - 10)			digit = *ptr - 'A' + 10;		else if (*ptr >= 'a' && *ptr < 'a' + base - 10)			digit = *ptr - 'a' + 10;		else			break;		ret *= base;		ret += digit;		ptr++;	}out:	if (end)		*end = (char *)ptr;	return ret;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -