Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- === modified file 'kernel/generic/include/typedefs.h'
- --- kernel/generic/include/typedefs.h 2015-06-01 00:04:05 +0000
- +++ kernel/generic/include/typedefs.h 2017-03-28 14:36:23 +0000
- @@ -58,7 +58,9 @@
- typedef volatile uint8_t ioport8_t;
- typedef volatile uint16_t ioport16_t;
- -typedef volatile uint32_t ioport32_t;
- +typedef volatile uint32_t ioport32_t;
- +
- +typedef native_t ptrdiff_t;
- #ifdef __32_BITS__
- === modified file 'kernel/test/print/print2.c'
- --- kernel/test/print/print2.c 2012-04-02 15:52:07 +0000
- +++ kernel/test/print/print2.c 2017-03-28 14:42:44 +0000
- @@ -51,6 +51,15 @@
- TPRINTF("Expected output: [0x11] [0x012] [0x013] [0x00014] [0x00015]\n");
- TPRINTF("Real output: [%#x] [%#5.3x] [%#-5.3x] [%#3.5x] [%#-3.5x]\n\n", 17, 18, 19, 20, 21);
- + char ch[12];
- + ptrdiff_t d, neg_d;
- +
- + d = &ch[0] - &ch[12];
- + neg_d = (unsigned)(-d);
- + TPRINTF("Testing printf(\"%%td %%tu %%tx %%ti %%to\", d, neg_d, neg_d, d, neg_d):\n");
- + TPRINTF("Expected output: [-12] [12] [c] [-12] [14]\n");
- + TPRINTF("Real output: [%td] [%tu] [%tx] [%ti] [%to]\n\n", d, neg_d, neg_d, d, neg_d);
- +
- sysarg_t nat = UINTN_C(0x12345678);
- TPRINTF("Testing printf(\"%%#" PRIx64 " %%#" PRIx32 " %%#" PRIx16 " %%#" PRIx8 " %%#" PRIxn " %%#" PRIx64 " %%s\", (uint64_t) UINT64_C(0x1234567887654321), (uint32_t) UINT32_C(0x12345678), (uint16_t) UINT16_C(0x1234), (uint8_t) UINT8_C(0x12), nat, (uint64_t) UINT64_C(0x1234567887654321), \"Lovely string\"):\n");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement