[PATCH] D97733: Fix infinite recursion during IR emission if a constant-initialized lifetime-extended temporary object's initializer refers back to the same object.
    Richard Smith - zygoloid via Phabricator via cfe-commits 
    cfe-commits at lists.llvm.org
       
    Mon Mar  1 14:03:29 PST 2021
    
    
  
rsmith added a comment.
@rjmccall We could alternatively address this by creating and registering the global first, and only then building and adding its initializer, but either way we're going to need some special-case code to detect and handle this situation (because we might need to change the type of the global to match the emitted constant). Happy to switch to that approach if you prefer.
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97733/new/
https://reviews.llvm.org/D97733
    
    
More information about the cfe-commits
mailing list