adonis0147 opened a new issue, #12843:
URL: https://github.com/apache/doris/issues/12843

   ### Search before asking
   
   - [X] I had searched in the 
[issues](https://github.com/apache/incubator-doris/issues?q=is%3Aissue) and 
found no similar issues.
   
   
   ### Description
   
   Currently, If we use clang to build the project, we can't view the contents 
of some objects (e.g. `std::string` objects) in gdb.
   
   An example:
   
   **source code**
   ```cpp
   #include <iostream>
   #include <string>
   
   int main() {
       std::string s = "Hello, world!";
       std::cout << s << std::endl;
       return 0;
   }
   
   ```
   
   **Debugging with GDB**
   ```gdb
   (gdb) l
   1       #include <iostream>
   2       #include <string>
   3
   4       int main() {
   5           std::string s = "Hello, world!";
   6           std::cout << s << std::endl;
   7           return 0;
   8       }
   (gdb) b 6
   Breakpoint 1 at 0x14e0e: file test.cc, line 6.
   (gdb) r
   Starting program: /ssd2/lingcong/misc/clang/test
   
   Breakpoint 1, main () at test.cc:6
   6           std::cout << s << std::endl;
   (gdb) p s
   $1 = <incomplete type>
   (gdb)
   ```
   
   ### Solution
   
   Add more debug info for clang build.
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to