diggita lemmy social
  • Communities
  • Create Post
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
RSS Bot@lemmy.bestiver.seBM to Hacker News@lemmy.bestiver.seEnglish · 22 days ago

C++26: The New Debugging Header

www.sandordargo.com

external-link
message-square
0
link
fedilink
  • cross-posted to:
  • lobsters@crustaceanson.theshelf.top
2
external-link

C++26: The New Debugging Header

www.sandordargo.com

RSS Bot@lemmy.bestiver.seBM to Hacker News@lemmy.bestiver.seEnglish · 22 days ago
message-square
0
link
fedilink
  • cross-posted to:
  • lobsters@crustaceanson.theshelf.top
C++26: the new debugging header
www.sandordargo.com
external-link
If you’ve ever needed to hit a breakpoint programmatically in C++, you’ve probably written something like this: 1 2 3 4 5 6 7 8 9 #if defined(_MSC_VER) __debugbreak(); #elif defined(__clang__) __builtin_debugtrap(); #elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) __asm__ volatile("int3"); #else raise(SIGTRAP); #endif Every major C++ project reinvents this wheel. Boost.Test has debugger_break(), Catch2 has CATCH_BREAK_INTO_DEBUGGER, Dear ImGui has IM_DEBUG_BREAK() and Unreal has UE_DEBUG_BREAK. The platform knowledge required is arcane but well-known to tooling implementers — it just wasn’t standardized. C++26 fixes this with P2546R5 and its companion P2810R4 thanks to Rene Ferdinand Rivera Morell. A new header provides…

Comments

alert-triangle
You must log in or register to comment.

Hacker News@lemmy.bestiver.se

hackernews@lemmy.bestiver.se

Subscribe from Remote Instance

You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: !hackernews@lemmy.bestiver.se
lock
Community locked: only moderators can create posts. You can still comment on posts.

NOTICE: The bot occasionally has downtime, sorry about that. I’m working on adding better monitoring and error recovery so I can get notified faster.

Posts from the RSS Feed of HackerNews.

The feed sometimes contains ads and posts that have been removed by the mod team at HN.

Source of the RSS Bot.

Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 496 users / day
  • 1.97K users / week
  • 3.88K users / month
  • 4.15K users / 6 months
  • 1 local subscriber
  • 5.71K subscribers
  • 3.24K Posts
  • 2.39K Comments
  • Modlog
  • mods:
  • patrick@lemmy.bestiver.se
  • RSS Bot@lemmy.bestiver.seB
  • BE: 0.19.20
  • Modlog
  • Legal
  • Instances
  • Docs
  • Code
  • join-lemmy.org