diff options
| author | Erik Desjardins <erikdesjardins@users.noreply.github.com> | 2023-05-18 17:53:03 -0400 |
|---|---|---|
| committer | Erik Desjardins <erikdesjardins@users.noreply.github.com> | 2023-07-10 19:19:37 -0400 |
| commit | 5f4472e45101dae008f375f6a2a3162500e6bc21 (patch) | |
| tree | a79bb3ed59e4c85233faee6ad3f8b36103a8effe | |
| parent | 84ff2e3d1cf8a2fb55ff639e635b5ab3b8283428 (diff) | |
| download | rust-5f4472e45101dae008f375f6a2a3162500e6bc21.tar.gz rust-5f4472e45101dae008f375f6a2a3162500e6bc21.zip | |
extern-fn-explicit-align test: add MSVC compatible alignment attribute
| -rw-r--r-- | tests/run-make/extern-fn-explicit-align/test.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/run-make/extern-fn-explicit-align/test.c b/tests/run-make/extern-fn-explicit-align/test.c index a015fc9aaf6..154b63ff45b 100644 --- a/tests/run-make/extern-fn-explicit-align/test.c +++ b/tests/run-make/extern-fn-explicit-align/test.c @@ -3,11 +3,20 @@ #include <stdint.h> #include <string.h> +#ifdef _MSC_VER +__declspec(align(16)) struct TwoU64s { uint64_t a; uint64_t b; -} __attribute__((aligned(16))); +}; +#else +struct __attribute__((aligned(16))) TwoU64s +{ + uint64_t a; + uint64_t b; +}; +#endif struct BoolAndU32 { |
