From 07b5c4934ce98d9f3431c23d5e56a46faba77360 Mon Sep 17 00:00:00 2001 From: mhauserr Date: Tue, 20 Aug 2013 23:50:15 +0100 Subject: Update c.html.markdown Added explanation of size_t --- c.html.markdown | 1 + 1 file changed, 1 insertion(+) (limited to 'c.html.markdown') diff --git a/c.html.markdown b/c.html.markdown index 24a96463..ae66fa78 100644 --- a/c.html.markdown +++ b/c.html.markdown @@ -81,6 +81,7 @@ int main() { // is not evaluated (except VLAs (see below)). // The value it yields in this case is a compile-time constant. int a = 1; + // size_t is an unsiged integer type of at least 2 bytes used to represent the size of an object size_t size = sizeof(a++); // a++ is not evaluated printf("sizeof(a++) = %zu where a = %d\n", size, a); // prints "sizeof(a++) = 4 where a = 1" (on a 32-bit architecture) -- cgit v1.2.3 From c4c8c02df970c028bd96f2e133a8bf76d5811fc5 Mon Sep 17 00:00:00 2001 From: mhauserr Date: Wed, 21 Aug 2013 00:02:33 +0100 Subject: Added explanation of size_t --- c.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'c.html.markdown') diff --git a/c.html.markdown b/c.html.markdown index ae66fa78..3acf1a4d 100644 --- a/c.html.markdown +++ b/c.html.markdown @@ -81,7 +81,7 @@ int main() { // is not evaluated (except VLAs (see below)). // The value it yields in this case is a compile-time constant. int a = 1; - // size_t is an unsiged integer type of at least 2 bytes used to represent the size of an object + // size_t is an unsiged integer type of at least 2 bytes used to represent the size of an object. size_t size = sizeof(a++); // a++ is not evaluated printf("sizeof(a++) = %zu where a = %d\n", size, a); // prints "sizeof(a++) = 4 where a = 1" (on a 32-bit architecture) -- cgit v1.2.3 From f6c800dd2aac61c69563a6d51b786928a1d6b329 Mon Sep 17 00:00:00 2001 From: Nathan Hoad Date: Thu, 5 Sep 2013 01:29:59 +1000 Subject: Fixed typo in c.html.markdown --- c.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'c.html.markdown') diff --git a/c.html.markdown b/c.html.markdown index 3acf1a4d..3ec4aeef 100644 --- a/c.html.markdown +++ b/c.html.markdown @@ -294,7 +294,7 @@ int main() { printf("%zu, %zu\n", sizeof(px), sizeof(not_a_pointer)); // => Prints "8, 4" on a typical 64-bit system - // To retreive the value at the address a pointer is pointing to, + // To retrievve the value at the address a pointer is pointing to, // put * in front to de-reference it. // Note: yes, it may be confusing that '*' is used for _both_ declaring a // pointer and dereferencing it. -- cgit v1.2.3 From 65d2460cd760812c0a0e7a08771d859f13eac3af Mon Sep 17 00:00:00 2001 From: Nathan Hoad Date: Thu, 5 Sep 2013 07:13:28 +1000 Subject: Fixed typo in c.html.markdown that I introduced --- c.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'c.html.markdown') diff --git a/c.html.markdown b/c.html.markdown index 3ec4aeef..12f862bc 100644 --- a/c.html.markdown +++ b/c.html.markdown @@ -294,7 +294,7 @@ int main() { printf("%zu, %zu\n", sizeof(px), sizeof(not_a_pointer)); // => Prints "8, 4" on a typical 64-bit system - // To retrievve the value at the address a pointer is pointing to, + // To retrieve the value at the address a pointer is pointing to, // put * in front to de-reference it. // Note: yes, it may be confusing that '*' is used for _both_ declaring a // pointer and dereferencing it. -- cgit v1.2.3 From 61dcca33407b75cb44ccc042ff213c1be0c2a5c8 Mon Sep 17 00:00:00 2001 From: Adrian Espinosa Date: Wed, 4 Sep 2013 23:32:18 +0200 Subject: Fix long line --- c.html.markdown | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'c.html.markdown') diff --git a/c.html.markdown b/c.html.markdown index 3acf1a4d..bc7bd37c 100644 --- a/c.html.markdown +++ b/c.html.markdown @@ -81,7 +81,8 @@ int main() { // is not evaluated (except VLAs (see below)). // The value it yields in this case is a compile-time constant. int a = 1; - // size_t is an unsiged integer type of at least 2 bytes used to represent the size of an object. + // size_t is an unsiged integer type of at least 2 bytes used to represent + // the size of an object. size_t size = sizeof(a++); // a++ is not evaluated printf("sizeof(a++) = %zu where a = %d\n", size, a); // prints "sizeof(a++) = 4 where a = 1" (on a 32-bit architecture) -- cgit v1.2.3