From 68b51e7a81a8d4ee0637d17782d7c43f5c2ca7fd Mon Sep 17 00:00:00 2001 From: Martin Date: Sun, 23 Apr 2017 04:47:21 +0200 Subject: [PATCH] Fix missing alignment for kernighan_ritchie allocator unittests --- .../allocator/building_blocks/kernighan_ritchie.d | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/std/experimental/allocator/building_blocks/kernighan_ritchie.d b/std/experimental/allocator/building_blocks/kernighan_ritchie.d index 35dd0f773..db42ced80 100644 --- a/std/experimental/allocator/building_blocks/kernighan_ritchie.d +++ b/std/experimental/allocator/building_blocks/kernighan_ritchie.d @@ -811,7 +811,7 @@ it actually returns memory to the operating system when possible. void test(int[] sizes) { - ubyte[256 * 1024] buf; + align(size_t.sizeof) ubyte[256 * 1024] buf; auto a = KRRegion!()(buf); void[][] bufs; @@ -853,7 +853,7 @@ it actually returns memory to the operating system when possible. void test(int[] sizes, int word) { - ubyte[256 * 1024] buf; + align(size_t.sizeof) ubyte[256 * 1024] buf; auto a = KRRegion!()(buf); void[][] bufs;