[PATCH] D85650: [llvm] support graceful failure of DataLayout parsing

Mehdi AMINI via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 15 17:18:28 PDT 2020


mehdi_amini accepted this revision.
mehdi_amini added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/include/llvm/IR/DataLayout.h:197
                            uint32_t TypeByteWidth, uint32_t IndexWidth);
 
   /// Internal helper method that returns requested alignment for type.
----------------
Is this a good idea to keep a duplication of every API that can fail? Couldn't we just offer the "safe" one returning an error?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85650/new/

https://reviews.llvm.org/D85650



More information about the llvm-commits mailing list