Skip to content

Commit 30b5bfc

Browse files
authored
Merge pull request #2463 from barracuda156/ppc_assert
parser_stype.h: allow building for ppc
2 parents 53fb1d3 + a2fc1d1 commit 30b5bfc

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/lpython/parser/parser_stype.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,10 @@ static_assert(std::is_trivial<YYSTYPE>::value);
112112
// Ensure the YYSTYPE size is equal to Vec<AST::ast_t*>, which is a required member, so
113113
// YYSTYPE must be at least as big, but it should not be bigger, otherwise it
114114
// would reduce performance.
115+
// A temporary fix for PowerPC 32-bit, where the following assert fails with (16 == 12).
116+
#ifndef __ppc__
115117
static_assert(sizeof(YYSTYPE) == sizeof(Vec<LPython::AST::ast_t*>));
118+
#endif
116119

117120
static_assert(std::is_standard_layout<Location>::value);
118121
static_assert(std::is_trivial<Location>::value);

0 commit comments

Comments
 (0)