在 Pascal 语言中,sizeof() 是一种内存容量度量函数,功能是返回一个变量或者类型的大小(以字节为单位);在 C 语言中,sizeof() 是一个判断数据类型或者表达式长度的运算符。 在Pascal 语言与C语言中,对 sizeof() 的处理都是在编译阶段进行。
以上来源于: WordNet
The 64-bit return value from sizeof in the following statement is truncated to 32-bits when assigned to bufferSize.
在下面这条语句中,在对 bufferSize 进行赋值时,从 sizeof 返回的 64 位值被截断成了 32 位。
This request asks for sizeof(data) bytes of data copied from the address in main memory denoted by argp to be copied into the object data.
这个请求会要求将 sizeof(data) 字节的数据从 argp 所指向的主存地址处拷贝到 data 对象中。
This structure has the useful property that if you allocate space for (sizeof(struct header) + 10) bytes, you can treat data as being an array of 10 bytes.
这种结构体的有用之处在于,如果您分配 (sizeof(struct header) + 10) 字节的空间,您可以像处理一个 10 字节的数组一样来处理数据。
malloc sizeof So, when I call malloc size of int and int on this system is probably 4 bytes or 32 bits so what am I getting back?
所以,当我调用,在这个系统中int可能是4个字节,或者说32位,那么返回的是什么呢?
So let me go ahead and rerun sizeof and hit Enter.
我们继续然后返回sizeof,敲Enter键。
Let's go ahead and run sizeof.
接着运行“run,sizeof“
应用推荐