[HN Gopher] Debugging the C++ standard library on macOS
       ___________________________________________________________________
        
       Debugging the C++ standard library on macOS
        
       Author : japrozs
       Score  : 18 points
       Date   : 2023-08-03 07:18 UTC (15 hours ago)
        
 (HTM) web link (www.jviotti.com)
 (TXT) w3m dump (www.jviotti.com)
        
       | gumby wrote:
       | I love that the dives right in to learn C++ and endorse their
       | enthusiasm.
       | 
       | However I am not sure reading the standard library sources is a
       | great way to learn early on. Those sources have a lot of
       | speciality code, and head-standing, to handle various obscure
       | corner cases, different architectures and the like. And it's so
       | great they do!
       | 
       | When you're still learning C++ all that extra care will probably
       | add to the learner's confusion rather than reduce it.
       | 
       | And in fact, very few people need to write code like that. When
       | they do, they will often resort to obscure corners of the C++
       | standard which were added for library writers (hence the common
       | response to a new standard, "why did the committee waste time on
       | an obscure feature like that?").
       | 
       | Also these libraries typically rely on compiler-specific features
       | that may not even be documented.
       | 
       | I don't mean to discourage anyone from reading the library
       | sources! But perhaps they are not the best place to start.
        
       | saagarjha wrote:
       | Of course, LLDB is more likely than not to be useless when
       | debugging complex templated code from the standard library :(
        
         | mistrial9 wrote:
         | what is the constructive part of this comment? the debugger
         | does what it is designed to do, and this author shows a clear
         | example of setting it up?
         | 
         | kudos to the clarity of this simple effort in the "tangled
         | forests" that are Modern C++
        
       ___________________________________________________________________
       (page generated 2023-08-03 23:01 UTC)