[PATCH] D154764: [ASTImporter] Fields are imported first and reordered for correct layout.
Shafik Yaghmour via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jul 27 17:35:49 PDT 2023
shafik added inline comments.
================
Comment at: clang/unittests/AST/ASTImporterTest.cpp:8018
+ int m() {
+ return &((A *)0)->f1 - &((A *)0)->f2;
+ }
----------------
So is it the case that this caused `f2` to be imported first and then `f1`? Which is the opposite of the example in the comments:
```
struct declToImport {
int a = c + b;
int b = 1;
int c = 2;
};
```
which causes the order to be c, b and then a.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D154764/new/
https://reviews.llvm.org/D154764
More information about the cfe-commits
mailing list