Commit 48c2dd8
committed
Replace alignment_of_long_double with C11 alignof if possible
This removes a static variable in a static function and uses
C11 `alignof` instead to get a compile-time value. Since we don't
currently require C11 we keep the old implementation as fallback.
Also fixes this compiler warning:
```
opal_copy_functions_heterogeneous.c:495:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
495 | alignment_of_long_double() {
| ^~~~~~~~~~~~~~~~~~~~~~~~
```
by adding `void` as parameter.
Signed-off-by: Joseph Schuchart <[email protected]>1 parent ff12b69 commit 48c2dd8
1 file changed
+14
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| |||
481 | 482 | | |
482 | 483 | | |
483 | 484 | | |
484 | | - | |
485 | | - | |
486 | | - | |
487 | | - | |
488 | | - | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
489 | 495 | | |
490 | 496 | | |
491 | 497 | | |
492 | 498 | | |
493 | 499 | | |
494 | 500 | | |
495 | | - | |
| 501 | + | |
496 | 502 | | |
497 | 503 | | |
498 | 504 | | |
| |||
503 | 509 | | |
504 | 510 | | |
505 | 511 | | |
506 | | - | |
| 512 | + | |
| 513 | + | |
507 | 514 | | |
508 | 515 | | |
509 | 516 | | |
| |||
0 commit comments