C++20 Concepts: A Day in the Life - Saar Raz - CppCon 2019

แชร์
ฝัง
  • เผยแพร่เมื่อ 12 ก.ย. 2024
  • CppCon.org
    -
    Discussion & Comments: / cpp
    -
    Presentation Slides, PDFs, Source Code and other presenter materials are available at: github.com/Cpp...
    -
    C++20 Concepts are right around the corner - and they are set to revolutionize the way we write generic code, allowing for much better code readability, error message readability and compile times; In this talk I will show how concepts can be used in a real project, and demonstrating those how these 3 traits indeed improve, using my implementation of the feature in the Clang compiler.
    Come to this talk to see how concepts greatly simplify generic code, and how you can expect to use them in C++20.
    -
    Saar Raz
    A tech and C++ enthusiast, Saar programs in C++ mostly in his free time. In late 2017, he volunteered to implement C++20 Concepts in the Clang compiler, and has been working on that since, having recently reached a feature-complete beta stage.
    Other than C++ and tech, Saar also likes graphic design and playing video games.
    -
    Videos Filmed & Edited by Bash Films: www.BashFilms.com *-----*
    Register Now For CppCon 2022: cppcon.org/reg...
    *-----*

ความคิดเห็น • 9

  • @enerjazzer
    @enerjazzer 3 ปีที่แล้ว +3

    Nice talk, good coverage of many details you're gonna face when you start writing with concepts

  • @OperationDarkside
    @OperationDarkside 4 ปีที่แล้ว +9

    That tree implementation looks really interesting. With compiletime strings you could even create html or other markup strings. An OpenGL UI would also benefit from that

  • @jaykickliter
    @jaykickliter 4 ปีที่แล้ว +15

    Good presentation, but this C++ is so exhausting. It never ends.

    • @funkmasterhexbyte1684
      @funkmasterhexbyte1684 4 ปีที่แล้ว +4

      Agreed, I was getting tired of how many times he had to write a new concept to define an old one, it seems to me that reading concept-using code is going to be a real drag without an IDE to jump around to definitions. That said, the end result is still extremely impressive.

    • @SamWhitlock
      @SamWhitlock 3 ปีที่แล้ว +2

      @@funkmasterhexbyte1684 at least what it replaces (inscrutable SFINAE errors) is a big win, plus the ability to do structural subtyping (e.g. a concept for "something that can be called() and return something convertible to a vector") is a nice way to avoid type inheritance in many cases.

    • @nextlifeonearth
      @nextlifeonearth ปีที่แล้ว

      @@funkmasterhexbyte1684 Sane naming of the concept should help with that. I have plenty of code that does similar stuff in runtime and is less concise, so this would be an overall win.
      Only disadvantage is that it puts more stuff in headers. Maybe modules can fix this in the future.

  • @DBZM1k3
    @DBZM1k3 4 ปีที่แล้ว

    Sean Parent has an interesting talk on runtime polymorphism. A couple of years ago which I feel would solve the inheritance issue while still keeping a similar structure from the beginning.

  • @dexterman6361
    @dexterman6361 4 ปีที่แล้ว +3

    Damn that's so cool!

  • @ZarviroffSerge
    @ZarviroffSerge 3 ปีที่แล้ว +1

    Weird intro. We are watching this, because we already care about it, because we need it. 11 minutes in, still nothing about concepts. :D