mastodon.ie is one of the many independent Mastodon servers you can use to participate in the fediverse.
Irish Mastodon - run from Ireland, we welcome all who respect the community rules and members.

Administered by:

Server stats:

1.6K
active users

#moderncpp

0 posts0 participants0 posts today
Mathias Hasselmann<p>I am pretty sure you all already know, but it's actually possible to have `requires` clauses at the end of a function declaration. Just like any other attribute.</p><p>This makes usage of ad-hoc requirements much more readable and greatly reduces the pressure to introduce custom concepts.</p><p>Why are so many teaching the front syntax instead of the tail syntax?</p><p><a href="https://mastodon.green/tags/Concepts" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Concepts</span></a> <a href="https://mastodon.green/tags/CPP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>CPP</span></a> <a href="https://mastodon.green/tags/CPP20" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>CPP20</span></a> <a href="https://mastodon.green/tags/ModernCPP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCPP</span></a> <a href="https://mastodon.green/tags/Programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Programming</span></a></p>
Mathias Hasselmann<p>You don't realize just how good C++23 is until you take some old C++ code, paste it into <a href="https://mastodon.green/tags/Godbolt" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Godbolt</span></a>, set the compiler flags to C++23, add a few concept-checking asserts, read the beautifully clear error messages from concepts, and fix your problem.</p><p><a href="https://mastodon.green/tags/ModernCPP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCPP</span></a> <a href="https://mastodon.green/tags/CPP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>CPP</span></a> <a href="https://mastodon.green/tags/Concepts" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Concepts</span></a> <a href="https://mastodon.green/tags/Legacy" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Legacy</span></a> <a href="https://mastodon.green/tags/Evolution" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Evolution</span></a> <a href="https://mastodon.green/tags/Happyiness" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Happyiness</span></a> <a href="https://mastodon.green/tags/Programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Programming</span></a></p>
Hannes Hauswedell<p>I wrote a blog post again:</p><p>𝗢𝘄𝗻𝗶𝗻𝗴 𝗮𝗻𝗱 𝗻𝗼𝗻-𝗼𝘄𝗻𝗶𝗻𝗴 𝗖++ 𝗥𝗮𝗻𝗴𝗲𝘀</p><p>The first article in a series discussing some of the underlying properties of C++ ranges, and in particular range adaptors.</p><p><a href="https://hannes.hauswedell.net/post/2025/05/17/non-owning-range/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hannes.hauswedell.net/post/202</span><span class="invisible">5/05/17/non-owning-range/</span></a></p><p><span class="h-card" translate="no"><a href="https://mastodon.online/@meetingcpp" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>meetingcpp</span></a></span> <span class="h-card" translate="no"><a href="https://mastodon.social/@c_discussions" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>c_discussions</span></a></span> </p><p><a href="https://mastodon.social/tags/cplusplus" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cplusplus</span></a> <a href="https://mastodon.social/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a> <a href="https://mastodon.social/tags/ranges" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ranges</span></a> <a href="https://mastodon.social/tags/views" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>views</span></a> <a href="https://mastodon.social/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a> <a href="https://mastodon.social/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.social/tags/SmallWeb" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SmallWeb</span></a></p>
Andreas Fertig<p>Why do C++ templates confuse so many developers?<br>Because the syntax is tricky, the errors are cryptic, and most tutorials don’t explain the why behind the how.<br>In my self-paced course, we fix that. Step by step, you’ll see how templates work, so you can write efficient, reusable code with confidence. Join now and start mastering!</p><p>And yes, you’ll also get a complimentary copy of my "Tips and Tricks with Templates" book when you book before April 30th.</p><p><a href="https://mas.to/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a> <a href="https://mas.to/tags/cpptemplates" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpptemplates</span></a> <a href="https://mas.to/tags/ModernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCpp</span></a></p>
Andreas Fertig<p>Templates in C++ are powerful – but they’re also one of the most misunderstood features.<br>Ready to rewind, revisit, and truly master templates on your term? Book before April 30th and get a free copy of my "Tips and Tricks with Templates" book.</p><p><a href="https://mas.to/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a> <a href="https://mas.to/tags/cpptemplates" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpptemplates</span></a> <a href="https://mas.to/tags/ModernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCpp</span></a></p>
Andreas Fertig<p>Do you struggle with C++ Templates? My C++ Templates course helps you understand how templates work and to apply them in your codebase.<br>Get a complimentary copy of my book, "Tips and Tricks with Templates" by booking before April 30th.</p><p><a href="https://mas.to/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a> <a href="https://mas.to/tags/cpptemplates" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpptemplates</span></a> <a href="https://mas.to/tags/ModernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCpp</span></a></p>
alexboly<p>What do you use for installing libraries that you need for C++? (Multiple choice available). Please boost for reach <a href="https://mastodon.social/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.social/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a></p>
alexboly<p>Question for C++ programmers: are there any libraries you are missing? I'm writing a piece on modern C++ libraries and I appreciate your input.</p><p><a href="https://mastodon.social/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.social/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a></p>
C++ on Sea<p>C++OnSea 2024 SESSION ANNOUNCEMENT: Temporal Dynamics: Exploring the Intricacies of Object Lifetimes in Modern C++ by Riya Bansal</p><p><a href="https://cpponsea.uk/2024/sessions/temporal-dynamics-exploring-the-intricacies-of-object-lifetimes-in-modern-cpp" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">cpponsea.uk/2024/sessions/temp</span><span class="invisible">oral-dynamics-exploring-the-intricacies-of-object-lifetimes-in-modern-cpp</span></a></p><p>Register now at <a href="https://cpponsea.uk/tickets/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">cpponsea.uk/tickets/</span><span class="invisible"></span></a></p><p><a href="https://vmst.io/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://vmst.io/tags/cplusplus" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cplusplus</span></a> <a href="https://vmst.io/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a> <a href="https://vmst.io/tags/objectlifetime" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>objectlifetime</span></a></p>
C++ on Sea<p>C++OnSea 2024 SESSION ANNOUNCEMENT: Temporal Dynamics: Exploring the Intricacies of Object Lifetimes in Modern C++ by Riya Bansal</p><p><a href="https://cpponsea.uk/2024/sessions/temporal-dynamics-exploring-the-intricacies-of-object-lifetimes-in-modern-cpp" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">cpponsea.uk/2024/sessions/temp</span><span class="invisible">oral-dynamics-exploring-the-intricacies-of-object-lifetimes-in-modern-cpp</span></a></p><p>Register now at <a href="https://cpponsea.uk/tickets/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">cpponsea.uk/tickets/</span><span class="invisible"></span></a></p><p><a href="https://vmst.io/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://vmst.io/tags/cplusplus" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cplusplus</span></a> <a href="https://vmst.io/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a> <a href="https://vmst.io/tags/objectlifetime" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>objectlifetime</span></a></p>
Alessandro<p>[TUTORIAL] Learn Modern C++ </p><p><span class="h-card" translate="no"><a href="https://feddit.it/c/programmazione" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>programmazione</span></a></span></p><p>"...una guida originale e autonoma per l'apprendimento dei fondamenti di Modern C++, destinata a costituire la base di un corso di autoapprendimento. Alcuni capitoli dipendono dal materiale presentato in quelli precedenti, per cui se ne raccomanda lo studio lineare. Ci sono anche post regolari che trattano argomenti o aree del C++ non presenti nel corso."</p><p><a href="https://livellosegreto.it/tags/programmazione" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programmazione</span></a> <a href="https://livellosegreto.it/tags/cplusplus" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cplusplus</span></a> <a href="https://livellosegreto.it/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a> <a href="https://livellosegreto.it/tags/dev" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>dev</span></a> <a href="https://livellosegreto.it/tags/tutorial" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>tutorial</span></a></p><p><a href="https://learnmoderncpp.com/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">learnmoderncpp.com/</span><span class="invisible"></span></a></p>
Mathias Hasselmann<p>Remember the days when <a href="https://mastodon.green/tags/Clang" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Clang</span></a> was the new kid on the block, pushing forward the smug old folks by implementing the newest and hottest stuff from <a href="https://mastodon.green/tags/isocpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>isocpp</span></a>? </p><p>Not so anymore: These days it always seems Clang for which I have to provide terrible fallback hacks, when trying to explore the hottest and nicest of <a href="https://mastodon.green/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a>, where <a href="https://mastodon.green/tags/GNU" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>GNU</span></a> and <a href="https://mastodon.green/tags/MSVC" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MSVC</span></a> just deliver.</p><p><a href="https://mastodon.green/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a> <a href="https://mastodon.green/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.green/tags/cxx" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cxx</span></a></p>
DennisAdventOfCode
Sean Murthy<p>I won't be the first to say this, but we need to retire the phrase "Modern C++". I mean, C++11 was 12 years ago. </p><p>I understand that branding was necessary back then due to significant changes in the language and library, but it is ridiculous to continue to cleave language versions like that.</p><p>For my part, I just removed "Modern" from a course title, and I'm not looking back. 🚀 </p><p><a href="https://hachyderm.io/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://hachyderm.io/tags/cplusplus" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cplusplus</span></a> <a href="https://hachyderm.io/tags/modernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>modernCpp</span></a></p>
Mathias Hasselmann<p>Ever wanted to <a href="https://mastodon.green/tags/switch" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>switch</span></a> on a <a href="https://mastodon.green/tags/QMetaType" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>QMetaType</span></a>, or just a random, non-literal constexpr char pointer, aka. <a href="https://mastodon.green/tags/string" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>string</span></a>? Search no more:</p><p><a href="https://gist.github.com/hasselmm/9cc5fb4404b52d28560b86cb468ca707" rel="nofollow noopener" target="_blank"><span class="invisible">https://</span><span class="ellipsis">gist.github.com/hasselmm/9cc5f</span><span class="invisible">b4404b52d28560b86cb468ca707</span></a></p><p><a href="https://mastodon.green/tags/cxx" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cxx</span></a> <a href="https://mastodon.green/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.green/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a> <a href="https://mastodon.green/tags/qt" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>qt</span></a></p><p><a href="https://mastodon.green/tags/programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>programming</span></a><br><a href="https://mastodon.green/tags/metaprogramming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>metaprogramming</span></a></p>
Mathias Hasselmann<p>So I finally have an example that underlines my gut feeling of the else-if-statements being <a href="https://mastodon.green/tags/harmful" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>harmful</span></a> in modern C++. </p><p>Consider test(char) being a function returning a std::optional&lt;&gt;:</p><p>if (const auto x = test('A'))<br> handle_a(*x);<br>else if (test('B'))<br> handle_b(*x);</p><p>The function handle_b() will receive the invalid optional returned by test('A') instead of the one returned by test('B') without the compiler providing any warning.</p><p><a href="https://mastodon.green/tags/cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>cpp</span></a> <a href="https://mastodon.green/tags/moderncpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>moderncpp</span></a></p><p>Maybe something for your blog, <span class="h-card"><a href="https://mas.to/@lefticus" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>lefticus</span></a></span></p>
Am I?<p><span class="h-card"><a href="https://mas.to/@lefticus" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>lefticus</span></a></span> it was very funny to hear you of all people, Mr. "I've started telling people I'm a youtuber" react that way to <a href="https://floss.social/tags/PHP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>PHP</span></a> on <a href="https://floss.social/tags/CppCast" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>CppCast</span></a>.<br><a href="https://floss.social/tags/ModernPHP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernPHP</span></a> has a lot of similarities to <a href="https://floss.social/tags/ModernCPP" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCPP</span></a>.</p><p>I haven't gotten very far in my own journey (hopefully next year I'll be modernizing a PHP code base) but you would download the jetbrains IDE, turn on all the tools, and take all the best practices hints.<br>It uses classes and defined interfaces and has a package manager, it really feels like a new language</p>
Am I?<p>The keynote from this years <span class="h-card"><a href="https://mastodon.online/@meetingcpp" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>meetingcpp</span></a></span> is already online. Great job! This is an interesting one, a real rollercoaster ride.</p><p>My takeaway is: try new things out and talk about the warts.</p><p><a href="https://floss.social/tags/MeetingCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MeetingCpp</span></a> <a href="https://floss.social/tags/Ranges" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Ranges</span></a> <a href="https://floss.social/tags/ModernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCpp</span></a> <a href="https://floss.social/tags/Cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Cpp</span></a></p>
Dennis<p><a href="https://mastodon.wormhole.eu/tags/introduction" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>introduction</span></a></p><p>Hab an der Uni-Bremen Informatik studiert zusammen mit <span class="h-card"><a href="https://chaos.social/@mortzu" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>mortzu</span></a></span> <span class="h-card"><a href="https://chaos.social/@msquare" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>msquare</span></a></span> <span class="h-card"><a href="https://chaos.social/@Inge" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>Inge</span></a></span> <span class="h-card"><a href="https://social.tchncs.de/@cvigano" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>cvigano</span></a></span> </p><p>Bin Softwareentwickler im Bereich Hausautomatisierung/Smarthome/KNX, eher ausschließlich mit <a href="https://mastodon.wormhole.eu/tags/ModernCpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ModernCpp</span></a> unterwegs. Aber nicht nur neue Projekte (mit C++20) sondern auch <a href="https://mastodon.wormhole.eu/tags/LegacyCode" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>LegacyCode</span></a> aus einem anderen Jahrzehnt.</p>