[llvm-bugs] [Bug 43195] New: 'this' is unavailable when entering constructor

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Sep 2 08:37:33 PDT 2019


https://bugs.llvm.org/show_bug.cgi?id=43195

            Bug ID: 43195
           Summary: 'this' is unavailable when entering constructor
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: stephen.tozer at sony.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

Created attachment 22460
  --> https://bugs.llvm.org/attachment.cgi?id=22460&action=edit
File containing the reproduceable case

When building the attached file with clang-cl using the flags "/Od /Zi" and
running the output with the Visual Studio 15 2017 debugger, evaluating `this`
at line 8 (before initialization) gives the result "Variable is optimized away
and not available.". This behaviour is different to both clang+lldb and pure
MSVC, both of which give `this` the address of the uninitialized object. This
occurs whether the MSVC linker or lld is used. 

clang version 10.0.0
Target: x86_64-pc-windows-msvc
Thread model: posix

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190902/17f33520/attachment-0001.html>


More information about the llvm-bugs mailing list