CppCast - CppCon Wrapup

Episode Date: November 19, 2015

Rob and Jason are joined by Jon Kalb to talk about this year's CppCon, his trip to the Kona standards committee meeting and much more. Jon has been writing C++ for two and half decades and doe...s onsite C++ training. He chairs the CppCon and C++Now conferences and the C++ Track for the Silicon Valley Code Camp. He serves as chair of the Boost Libraries Steering Committee and is a Microsoft MVP. News Using variadic templates cleanly A sad story about get_temporary_buffer C++ and zombies: a moving question Jon Kalb @_jonkalb Exception-Safe Coding in C++ Links CppCon 2016: Announcing 2016 Dates CppCon 2014: Exception Safe Code (Part 1)

Transcript
Discussion (0)
Starting point is 00:00:00 Episode 35 of CppCast with guest Jon Kalb recorded November 3rd, 2015. In this episode we discuss zombies in C++. Then we'll interview CPPCon chair John Kalb. John will tell us how this year's conference went and much more. Welcome to episode 35 of CppCast, the only podcast for C++ developers by C++ developers. I'm your host, Rob Irving, joined by my co-host, Jason Turner. Jason, how are you doing today? Doing good, Rob. How are you? Doing pretty good.
Starting point is 00:01:06 I wanted to share this quick piece of feedback before we get to our guest today. This one comes from an iTunes review. And it's a bit long. I'm not going to read the whole thing. But they're saying it comes from someone named the handle Hackworks. And they say the podcast series contains the right amount of topics and depth to incite your inquisitiveness to read more. I look forward to new episodes each time I finish listening to an episode. Jason and Rob are wonderful hosts and treat the guest speakers with respect. This is one of the many aspects that make this series stand out compared to a few other podcasts
Starting point is 00:01:37 where the hosts try to belittle the guest speakers and come out as show-offs. I kind of thought this was an interesting piece of feedback. I'm not sure what other podcasts this person is listening to. But yeah, I would definitely never try to belittle the guests. And it's easy not to because the C++ guests we have on the show are always so intelligent. Maybe he just listens to like political talk radio podcasts or something. Maybe. That must be it. Anyway, we'd love to hear your thoughts about the show. You can always email us at feedback at cppcast.com, follow us on Twitter at twitter.com slash cppcast,
Starting point is 00:02:12 or like us on Facebook at facebook.com slash cppcast. And we always appreciate the iTunes reviews as well. So joining us again today is John Kolb. John has been writing C++ for two and a half decades and does on-site C++ training. He chairs the CppCon and C++Now conferences and the C++ track at the Silicon Valley Code Camp. He serves as chair of the Boost Library Steering Committee and is a Microsoft MVP. John, welcome back to the show.
Starting point is 00:02:40 Well, thanks very much for having me back. And if I can editorialize about that feedback, I would say that one of the things I really like about the C++ community is that what I normally see is people treating themselves with a lot of respect. It's not always, not 100%, but I think what I like to see at conferences is when people disagree, but they do it in a respectful, proper way. And that's what I see. Maybe that's the norm for tech conferences because I don't really go to that many. I go to C++ ones, but I really enjoy the professionalism we share with each other. And I can't really imagine a C++ podcast where the host belittles the guest. It's a little hard to imagine. Yeah. where the host belittles the guest. It's a little hard to imagine. But anyway, I want to say that since I was on,
Starting point is 00:03:30 the podcast has really taken off. It's been really successful. And I hear lots of good stuff about it. And so I've been cheering you guys on from the sidelines. Well, thank you so much. Thank you. Oh, yeah. And I want to thank you for being a community sponsor for CppCon and for having so many CppCon and C++ Now speakers on as guests.
Starting point is 00:03:53 I think that is kind of a support for the conference. It's been a huge help to us, really, to be able to pull from this pool of excellent speakers and excellent potential guests because of the conferences. Yeah, John, you've been a really great help to us, so we really appreciate it. Well, like I said, I'm happy to do it. So we had a couple news items we wanted to go through first. This first one is using variadic templates cleanly. And it's basically about using variadic templates in your code
Starting point is 00:04:27 and avoiding recursion. And I thought this was a pretty good article. Jason, do you want to go into this one at all? Yeah, first I've got to ask Rob, by any chance are you able to actually use C++11 features variadic templates on work yet? No, not yet. We're switching to C++11 now-ish.
Starting point is 00:04:46 We're in the process of it. Now-ish. Yeah. Well, this, I think, you know, it gives... Well, as Rob said, you know, it's a potential solution for things that you need to do iteratively without introducing template recursion into your code.
Starting point is 00:05:02 And the main thing that struck me staring at it was, can this improve my compile times? And also, I think in some cases, it can make the code more readable. I don't really know how to get into it over the air for exactly what they're suggesting, though. One of the things I thought was a little... Go ahead, John. I was just going to say that I think to describe it to people
Starting point is 00:05:24 who haven't read it yet, but I would encourage people to read it i i thought it was great and it caused me to think about variadic templates a little bit differently and that's always wonderful it's not a hack it's it's a different approach because my kind of i don't know what to say initial assumption working assumption was just oh you're doing um variadic parameters over the course we're gonna we're gonna use recursion and he's saying no you don't need to use recursion you can do template unpacking in a non-recursive way and it it doesn't work exactly the way you'd you know the most straightforward possible way you'd like to be able to unpack a parameter pack into a series of statements, but you can't do that. It has to all be in one statement. And so he's showing you a couple of tricks
Starting point is 00:06:11 so that you can do the unpacking and still keep it in one statement but not do recursion. And one nice thing he's also showing is also a way to use initializer lists and take advantage of the fact that initializer lists are guaranteed to be in order because if you unpack, for example, if you unpack a pack and make each item in the pack a parameter of a function call, for example, there's no guarantee the order in which those parameters are evaluated. In practice, of course they're going to be evaluated, you know, left to right.
Starting point is 00:06:49 They're just going to happen. But there's no guarantee of that. And so you wouldn't want to rely on that. And if you had a situation where you said, no, I need to be certain of that, then by putting in an initializer list, the initializer list does, in fact, guarantee order of evaluation. And that is an interesting insight and a nice little tool. So I'm really pleased with this article. I liked it a lot.
Starting point is 00:07:12 I think I did find there's a syntax error in it where he's missed the dot, dot, dot in his tuple iterators. But that's kind of minor. And the ideas are really, really great. I'm really glad you pointed that out to me, Rob. I would like to mention there's been two cases working in my open source projects where I have seen Clang handle order of operations
Starting point is 00:07:37 differently than I expected, where I would see crashes only on GCC, I mean, only on Clang and not on GCC because things were being evaluated differently than I expected in my parameter list. So it's not, you know, it's definitely not guaranteed. Was that specific to usage of variadic
Starting point is 00:07:53 templates? No, no, no. That was in reference to John saying that you can use parameter package, excuse me, you can use initializer list expansion to guarantee the order of operations and i would say that's a good plan because there's yeah two cases where i was accidentally um let's see i was passing in a value and then moving the value uh in the same statement which was a very
Starting point is 00:08:19 bad thing to do i shouldn't have been doing it on clang it crashed because the move was being evaluated before the the pass of the argument and GCC, it was being evaluated the opposite order. Interesting. I think Herb had, I don't know, I assume he wrote a paper. I didn't read the paper, but he was talking about it in a talk. He was talking about proposing that parameter evaluation order become specified. I wouldn't like that. The left to right that everybody, well, what he's saying is, you know, professional programmers, even, you know, like somebody like Jason can get bit by it, but at least he understands it when he sees it.
Starting point is 00:08:56 It's, oh, that's right, this is not guaranteed. But for beginners, why should you have to explain to a beginner, oh, by the way, even though you read it left to right and you think obviously it's going to be evaluated this way, but it's not. So the reason it's not is so that optimizers have another degree of freedom to do magic. But the question is, is that magic actually possible? And not being a compiler writer, I can't tell you, oh, yeah, if we had to do this in a specific order, that would really tie our hands. And I think what Herb was trying to make the case is, you're not going to cost you
Starting point is 00:09:30 much in performance, but it's going to make learning to use the language a lot easier. So I don't know. I haven't seen where that proposal went. So I'm assuming it didn't get traction. I have to get Chandler on here and give him a hard time for it. Okay, so this next item comes from Reddit, where someone actually just posted a screenshot from a book that came out last year, which was written by Alexander Stepanov. It's called From Mathematics to Generic Programming. And there's this little excerpt in the article telling the sad story about the function getTemporaryBuffer in the STL.
Starting point is 00:10:23 And apparently, when the function was first written, it was a very impractical implementation where it would repeatedly call malloc to try to malloc very large hunks of memory. And you would try to allocate gradually smaller ones until it was able to successfully get a valid pointer. And he put a comment in the code saying, this is bogus, don't use it. But he later found out that all the major STL implementations were using that code and they just took out the comment. And I was wondering if you had an opinion about this, John, or have you
Starting point is 00:10:45 heard the story before since you've worked with Alexander Stepanov? Yeah, he mentioned, you know, the book is based on a class that he taught at A9. So one of the great perks of being at A9 is to be able to sit in on his classes. Although those classes are now all on YouTube, so you can still see those classes, but I think, I think it was in a class when he mentioned this and maybe it was in person, but, but he, yeah, he talked about this. The thing is he makes it sound worse than it really is. I mean, all that's really happening. I mean, his description of it is, Oh, I want to grab as much memory as, you know, physical memory as the machine has, which is kind of a scary thought.
Starting point is 00:11:28 But all he really means is that, you know, he's trying to do like a stable sword, and if he had a temporary buffer that he could use, it would be more efficient. But he could do it without the temporary buffer or with a smaller than optimal size. So what he does is he tries to allocate a buffer of size n, where n is, you know, the number of items that he's going to try to put in it. And if that fails, then he reduces n and tries again. And what he's saying is, theoretically, you could write, you know, if you're not tied to trying to write portable code, which, of course, a library implementer never is. A library implementer is always implementing
Starting point is 00:12:07 for a specific compiler OS combination, right? So the library implementer can cheat and say, oh, I'm going to make system calls that are not portable because that's what the library is allowed to do. And so what he was saying is you could do better than this by calling the operating system and say, well, how much memory could you give me? And if you can't give me the full amount, then rather than ask for the full amount and ask for a little less and ask for a little less, you can just tell me how much I can ask for. And so it's not really an awful algorithm because almost all the time it's going to succeed. And in fact,
Starting point is 00:12:45 and I think this is where the weird thing is, I don't think most people are aware of this, but on Linux, my understanding is that malloc will essentially never fail. Even if you're completely out of memory, even out of virtual memory, the malloc will succeed. Now, when you try to access the memory, then you're going to fail. But malloc won't actually fail. So I'm not sure that the algorithm is actually going to do anything anyway, at least on Linux. It's an interesting thing, though, that there's a number of things that Alex has talked about where he had ideas about implementation
Starting point is 00:13:23 that actual library implementers today have not followed what he wanted followed. And that's somewhat frustrating for him. Things like, his idea was that the size of an empty vector should be the same as a single pointer. In other words, he wanted to put the size of the vector, stick that into the allocated memory. Does that make sense? So when the vector's empty, all you have is essentially a null pointer. But when you allocate the vector, then where the vector points to the first element is not actually the beginning of the buffer that's been allocated. So you back up a little bit and you put in the size of the buffer and the number of items
Starting point is 00:14:09 that are currently in the buffer and store that as part of the buffer. And then your empty vector is really small. And in talking to implementers, and I think i've talked to both uh stefan about this and also about howard and their their kind of point of view was well in order to do anything you're going to have to then do an extra dereference the reason that alex didn't do that initially was because the compiler he was using he couldn't get the cast to work he couldn't he couldn't figure out how to coerce the compiler into into making that. So he just wrote it kind of the way vectors are implemented now with three pointers.
Starting point is 00:14:51 But he thought that that was the correct way to do it and thought that that's how it should be. But I've talked to implementers now and they basically say, you're going to take a performance hit because almost anything you do, you're going to have to do this extra dereference just to get at that other thing. So I don't know. I don't think anybody's ever profiled it, but that's one of the things that he's talked about that he has ideas about how implementation should happen that are different than what they actually are for most implementation.
Starting point is 00:15:21 Okay. This next article is from Jens Weller from Meeting C++, and it's titled C++ and Zombies, a Moving Question. And John, I know you were very interested in this article. Maybe I should just let you introduce it. Oh, I think it's a right on article. Jens has done a great job of pulling out, I think, something that needs to be thought about. And I think in talking about move semantics, we've focused on how to implement movable types and how the move semantics can be implemented. But we haven't really talked much about how people writing code that uses std move or has moved from objects and what they should do. And, you know, the first thing I would point out is that the problems that he's talking about never happen if you're talking about natural R-value objects. These only happen when you
Starting point is 00:16:21 actually use standard move to cast something, right? Because with a naturally occurring temporary object, you never have a moved from object. So it's only an issue in the situation where you're using std move. And so you know, by looking at the code, this can possibly happen because you see std move sitting right there. But I think that in the article what he's talking about is what he's calling zombie objects. It's an object that's been moved from but hasn't been prepared to be destructed. So it may, for example, have a dangling pointer or something like that. So when you call a destructor on the object, it will corrupt because it wasn't cleaned up properly on the move. And I think that's part of what we train people to do,
Starting point is 00:17:10 that when you move from an object, you need to clean it up. But I think there's something else going on here that he's also talking about, and that's where he's talking about Sean Parent considering destructive moves and things like that. The idea being, the question that's being asked is, what is it that you can make, what assumptions can you make about a moved from object? And so what I would say is, we're thinking about that kind of the wrong way. If you imagine the code, and I realize on audio it's tough to write code, but this is a really simple code. Imagine the code that's just int i semicolon.
Starting point is 00:17:51 And, you know, so what operations can you perform on i? In other words, it's a declared value that isn't initialized. And so what can you perform on it? Well, most people would say, well, the only thing you can do is you can write to it. Well, actually, there's two things because you can also destroy it, but destroying it is trivial. But it turns out that any other operation, any operation that relies on the value of i, or even any operation that assumes i has a value, is undefined behavior. And Alex Stepanov has a term for this. He calls this a partially formed object. In other words, it's an object that has a type, but it doesn't yet have a valid value because it hasn't been properly initialized. And this turns out to be the exact same set of properties that we want from a move from object. If you move from an object, there's only two valid things you can do with it. One is you can destroy it,
Starting point is 00:18:41 and the other is you can assign to it. So it's essentially the exact same thing as a, you know, in this situation, a declared integer that hasn't had anything assigned to it. And so that, I think, is the correct way of thinking about a moved from object, that it is a partially formed object. And the only valid things you can do are let it go out of scope and get cleaned up or assign something to it, in which case it's now a valid object. And so he talks about Eric Niebler, who's arguing that a library writer should make it so that a move from object still supports all the invariants of the class.
Starting point is 00:19:24 And Eric is not just a library writer. make it so that a move from object still supports all the invariance of the class. And Eric is not just a library writer. He's one of the very best library writers out there. He's brilliant. And what he's trying to do is he's trying to hold his code to the highest possible standard. And what he's saying is that if the invariance of a class don't hold after an object is moved from, then they aren't really invariants. And so you have to keep the object not just in a state where you could assign to it, but it has to be a state where any operation that's performed on that object, as long as it doesn't have any other preconditions,
Starting point is 00:20:00 they should be callable on a moved from object. And that's, in fact, if you look in the standard, that's what the standard says about standard types. It says, for example, if you move from vector, you can still call empty on vector, or you can call size on vector, and it will do the right thing. But I think this is a mistake, and I think the standard committee has even made a mistake in this. And I think the problem is that we're thinking about this from the point of view of trying to make the library as complete as possible instead of thinking about how we want users to think about and use our objects. And what we need to think about is, let me put it this way. Suppose I had some uninitialized memory and I'm about to do an in place new. I'm about to put an object where this memory exists.
Starting point is 00:20:49 And before I do the in place new, I do a cast on the address of the memory and I cast it into a pointer to that object. And then I call a member function of the object. Would you expect that to work? Well, it's undefined behavior, but more importantly, of course you don't expect the invariance of the object to apply before the object's been constructed. It's before the lifetime has started. And what I'm saying is, what I'm arguing is, that that's the way we should think of a move from object. It is no longer an object. Its lifetime has been suspended, and the invariants don't hold. It is possible with some, many in fact, perhaps even most objects, to have trivial implementation such that after
Starting point is 00:21:36 you move from it, you can still do all the things you want to do, and that's really cheap. But I think that's not the correct way to think about it. And I think the correct way to do it is for the library to say, a move from object is you've suspended the lifetime of this object. If it's not reassigned, then the lifetime is ended. And the invariants no longer hold. And calling any other function other than assignment or destruction is undefined behavior. And you could say, well, that means the invariants don't hold. And I would say, no, the invariants don't hold because the object is no longer in its lifetime. It is in this weird, suspended, you know, doesn't count kind of thing.
Starting point is 00:22:18 And I think, I mean, you could say, well, what's the problem? Because it's not that expensive for most objects. Like I said, it's not that expensive to implement some safe thing. But we're encouraging people then to think about the wrong things. Because I don't think, I've never seen a use case that makes sense to move from an object and then make assumptions about the object. Right? So we don't want to encourage people to do that. I don't think we should document it. I think the library should say, you move from the object, anything you do with that object other than assignment or destruction is undefined behavior.
Starting point is 00:22:52 And one of the things that Jens talks about is Sean Parent talking about how you could do destructive moves, which is to say, go ahead and clean the object up on move so that we don't have to call the destructor later. And that actually has some efficiency advantages. But the problem is, we can never do that now. Sean wasn't actually, he was showing how it could be done. He wasn't actually proposing it, but he mentions, Jens mentions that other people have actually made a proposal, but we can't do this. Because right now, it is legal, according to the standard, to move from an object, move from a vector, and then call empty or size on it. And if you did a destructive move, that would no longer be legal, so that would
Starting point is 00:23:35 break code. And I think the correct thing, again, I think the standards committee made a mistake on this. I think the correct call would have been to say, once it's moved from, anything you do with it is undefined behavior, except, as I say, assignment or destruction. So I think we should encourage clients to say, don't make any assumptions about a move from object. And I think on the implementation side, of course, the library can implement any way it wants, because by definition, it's undefined behavior. But I think the correct implementation would be to somehow, at least in debug bills, warn developers and say, hey, that's a move from object, you're doing an operation that you shouldn't be doing. Yeah, I was thinking, I agree with you,
Starting point is 00:24:16 if for no other reason than it gives the authors of static analyzers a specific target to say, a moved from object has been used. Now I'm going to raise a warning in my static analyzers a specific target to say a moved from object has been used now i'm going to raise a warning in my static analyzer yes because as i say if you if you're doing anything with the move from other than as i say assigning or destroying it then you probably have a logic error there's just no use case where that's oh that's what i want to do i want to move from it and then make assumptions about it. Is this something that could potentially change in the future with the Sarens Committee? Do you think there would be any will to change it? Well, like I said, if they did now, because they've
Starting point is 00:24:56 already published a standard that says, oh, it's legal to move from an object and then do operations on it, then they would break code of anybody who's doing it. I hope people aren't doing that. I would hope it wouldn't be much code. But, you know, the standings committee, rightly so, very conservative. I'm not advocating that they change it at this point. I'm just saying that it's our job as, you know, community leaders or teachers,
Starting point is 00:25:22 whatever our role is, to try to encourage people to think about this the best possible way and i think the way we've been talking about is the way which is to say you know don't encourage people to do those kinds of operations after they move from an object sounds good to me well bringing up community uh cpp con 2015 finished a little over a month ago uh i think all the recorded sessions are now online. There's still a lot to consume there. Wanda, I see how you felt about this year's conference. Well, I'm kind of biased, but I think it was pretty good. Attendance
Starting point is 00:26:00 grew by about 20%. I thought the energy at the conference was really exciting. I got a lot of positive comments, and that's kind of consistent with the survey results we looked at. I think it's starting to become an event. I think people are starting to see this as a highlight of their programming year, and that's what I'm excited about. We added some new things to this conference that we hadn't had with the first one. We added a pre-conference class, which went really, really well. We had a meeting of the Study Group 14 14 which is game developer and low latency and it met
Starting point is 00:26:47 during the conference one day of the conference they met right on site and i think that was very well received and of course i think the conference can can take some credit for even the fact that that study group was created because it was largely created because of what happened at the first cpp con we got some we worked really hard we got a game developer as a keynote we tried to reach out to game developers as speakers we got a good response from the game developer community that was great and then we got people on the standards committee talking to game developers and then at the meeting on nexa they formed the study group specifically for this there's been a lot of work on email but the very
Starting point is 00:27:31 first face-to-face meeting was at the conference and so that's you know all stuff i'm really happy because because the goal with cpp con was to kind of be the platform for people to get together and talk about c++ you know through the C++ through all of mainstream C++. So I see we've got some evidence that that's what we've been able to achieve. That makes me very happy. So the talks are all up on YouTube, and they are slowly coming up on Channel 9. Is that right? So the situation with the channel nine they have
Starting point is 00:28:07 the plenaries were put up very quickly as they were on youtube we got those up really quick and the all of the editing was done and as the editing was done the guys that were editing they they uploaded it to youtube so everything is on YouTube right now. After that's done, all the edited videos were put on a hard drive and shipped to Redmond. And so the guys at Channel 9 have the drive, but I think there may have been someone who was out of town either at a conference or something like that. So there was some delay, but I think they're now in the position where they're going to start processing those and getting them up um just yesterday as we record this we had um there's a kind of a teaser that channel nine did where they interviewed 20 speakers or something like that well several different speakers and put together a little um video that was on the as as I say, it's the front page of Channel 9. It's kind of a little teaser about what different speakers are going to be talking about. And so that's up now. And so the
Starting point is 00:29:13 only thing that's on Channel 9 right now is that talk and the five plenaries, but the others are on their way. And I would say, you know, Channel 9, we love having Channel 9 because we've already been contacted by a couple of different developers who are from countries where YouTube is blocked. Because, of course, YouTube has all sorts of content. And Channel 9 is not blocked because Channel 9 is tech only. And so it doesn't have, you know, political censorship't out there so channel nine also lets you download talks for offline viewing and lets you do audio only audio only talks which generally aren't great for talks because you can't see the code but we do have panels and stuff like that so those are great for yeah for audio talks that is a really great feature of channel nine being able to download three or four talks and
Starting point is 00:30:03 get on a plane and watch them all while you're up in the air without internet. It's pretty helpful. So, your talk from CppCon this year was called The Beast is Back, and it seems to be one of the few sessions that isn't available. What happened there? Well,
Starting point is 00:30:20 the reason is I didn't submit this. It's not, that talk's not terribly technical. Okay. It's about, I mean, it's technical in a sense. It's about the language, about why people use it. So there's a lot of technology in it. But I should say there's no lines of code in it.
Starting point is 00:30:36 There's no, I don't think there's any code at all in any of the slides. It's not how to program in C++. It's more why people are choosing C++, why it wasn't as popular in the 2000s when it kind of got sidelined by Java and things like that. So I didn't submit it for the regular program, and so that meant it went into our open content. And one of the things I'm very happy and pleased about the conference
Starting point is 00:31:02 is that we have, now they're not the best times. They're either early in the morning or they're in the evening or they're at lunchtime. But we have certain slots that are designated open content slots. And anyone can say, I would like to speak on this subject. And so I just submitted this as an open content talk. And so our policy is that we don't record those talks. We record the regular program, the lightning talks, the sponsored panels, but we don't do birds of a feather and other open content talks. So I didn't want to make a special exception. So that's why it's
Starting point is 00:31:37 not recorded. But I'm also, as I said, it's not really, you're not going to learn C++ from watching the talk. I think it's a lot of fun. I think people enjoyed it. I love giving it, but it's, um, you'll just have to, um, invite me to your town and I'll give it in person. And this talk was based on an ebook that you released, right? Yeah. Well, there's actually, there are physical versions of the book, too. Oh, okay. It was written by O'Reilly because O'Reilly likes to do what they call a report. And calling it a book is a little bit of a stretch. It's like 60 pages. So it's really a booklet. But they do these free reports in areas that they think are taking off.
Starting point is 00:32:20 So they're usually new technology like Rust or something like that. And for them to do this at C++ kind of indicates that they think that C++ is taking off and they want to do C++ books. And so they distribute these books online. If you give them your email address, then, you know, so they can do marketing about other C++ books. So that's why they did this book. So it is free and and if you have it we'll we'll put the urls in in the show notes so people can download it awesome so another uh talk you're involved with directly at cbb con was a community building panel and this was actually one i was really interested in attending myself but i unfortunately wasn't able to make it
Starting point is 00:33:02 how did that panel go i think it went very well we heard from a number of different people um because and i deliberately wanted to make this not a user group panel but instead a community panel and that's because i wanted to include include online communities like podcasts, but also cprogramming.com and other online communities. Because I think there's a lot of overlap with interest. It's all about building these connections and trying to get an idea about what is the proper way to program C++ and to talk about C++ and to teach people how to do it and answer questions about it and those kinds of things. So we got to hear from Jens Weller, who wrote that article we talked about earlier. And for people in your audience who don't know, Jens is like a master builder in the community area.
Starting point is 00:34:08 So I first met him at the first C++ Now. He came and we sat down in the bar and had a long chat. And he told me that he thought C++ Now was really exciting. And he wanted to build a conference in Europe modeled on C++ Now. And of course, I was excited and supportive and everything, but it was like, I'm not sure if he realizes how big a challenge it is to run a conference, let alone start one from scratch. But he did it. That very same year, he launched Meeting C++ in Europe. And I think the first year out, it had more attendees than that year's C++ in Europe and I think the first year out it had more attendees than that year's C++ now. Oh, wow.
Starting point is 00:34:46 So he definitely did it. Every year it has grown. And so he also then, he has launched over a dozen, I'm not really even sure how many he's launched user groups, most of which in Europe, maybe a couple in, I think he's one or two in South America as well. So he works with a lot of people to start up local groups. And if any of your listeners are on Twitter, they're almost certain have seen at Meeting CPP because he is really active on Twitter and other social media stuff. So he kind of, you know, bridges the, you know, spans the gap between online conferences and user groups, but also, I mean, in-person conferences and user groups, but also online stuff too. So it was great to hear from him. He's got a lot of good ideas about how to start a group and, you know, what to do. So
Starting point is 00:35:43 I thought it was a great meeting. We had, I thought, a pretty good turnout for an 8 o'clock in the morning meeting at a conference that's just packed with other stuff going on. Yeah, I think we've mentioned meeting C++ a couple times before on the show, and one thing I really love about that is I think every month they post all the user groups that have been announced, like all the individual user group meetings.
Starting point is 00:36:06 So if you're ever looking for a C++ user group in your area, it's really a great resource. Most of the ones listed on the site are in Europe, but I think he does post all the ones that he's aware of in America and elsewhere. Yeah, right. elsewhere yeah right and i would i would encourage anybody um if if you are at all interested in a local group get on meetup and see what's there there's one that just started in australia oh wow and i just heard about that yeah i don't think they've even had the first meeting but i saw a meetup announcement of it and so yeah get on meetup and find out if there's a C++ group in your area and contact them and ask when the next meeting is. And if they say, well, we don't have one scheduled and say, hey, I'll talk.
Starting point is 00:36:57 So also, last time you were on this show, which was the very first episode, was right before the last C++ Now 2015. How did that conference go? Well, I should be asking you that question, Jason. Because what happened was, it was about the, I remember it was the second or third day, I started to feel really bad. And I ended up spending about half the conference in my hotel room oh no bed i was just yeah it was just it was really disappointing for me because as you can expect you know this is um a highlight of my year i work you know work on this conference and i don't get to go to as many sessions as i would like to anyway, because, because I'm, you know, doing all the, uh, all the
Starting point is 00:37:46 back, you know, behind the scenes stuff, but I get to go to some, but not this time. I, uh, like I say, the only sessions I went to in the second half of the conference were those that I personally had to, had to be present for. So the kickoff meeting and the, and the closing meeting were about the only things I attended. I knew you had gotten ill, but I didn't know it was half of the conference. Yeah, yeah, it was really disappointing. And I was sick for like the entire next week, too. Usually when I get the flu or something like that, it's a few days and I'm feeling better. But this was pretty bad.
Starting point is 00:38:24 But I got good feedback i think uh i think it it proves that i don't have to be around for people to have fun i guess i should have known right i will say um it is a great conference and a in a beautiful venue in an intimate setting and a good way to get to know uh other developers in a pretty laid back, relaxed environment. Yeah, I've kind of, you know, when I first started going, I said, wow, you know, Aspen is not the easiest place to get to. And I was kind of focusing on that. But the longer I've been going, the more I appreciate that once you're there, it is an amazing environment. You know, I don't know if being surrounded by beautiful mountains and beautiful sights actually helps you think about C++.
Starting point is 00:39:12 But it certainly does help you relax and kind of put the chaos of the rest of the world around you. You're there, and it's a different different experience and you're surrounded by other people who are over there too. It's, it's a kind of slow paced conference in a way. The sessions are long, the breaks between are long and, and we have, you know, a lot of time to talk with each other. And so I think it's, I think the venue adds more to the conference than I initially appreciated. And I would like to say, I do not think Aspen is difficult to get to at all. I just hop in the car,
Starting point is 00:39:49 drive down I-70. It's, I think it's a perfect location for a conference. Practically your backyard. Practically just, you know, three hours away, but you know,
Starting point is 00:40:02 it's fine. Going back to C++ Now and CppCon, has planning already started yet for next year's conferences? Yeah, absolutely. This year is going to be the 10th anniversary of both BoostCon and C++ Now together. The first five years we called it BoostCon, and the last five years, or the last four years,
Starting point is 00:40:28 and then this next year it's C++ Now. So this will be the 10th anniversary. Oh, wow. And I would like to tease you with all the great stuff that we have planned, but we haven't quite figured it all out yet. So I'm not sure what we're going to do to make it special, because part of it is, as I sit down and say, well, we could do this. And it's like, well, where would we put that?
Starting point is 00:40:49 Because the program is kind of packed with great content now. And so it's not like, oh, well, here's a new event because we don't have anything going on then. There's usually something going on most of the week. So we're still playing around with what we're going to do to to kind of celebrate the 10th anniversary but yeah we definitely are planning there and um cpp con even though it's really just been a little over a month away we've already as you mentioned we got the the videos up we just this morning announced dates for next year. It's going to be the week of September the 18th, so circle your calendar. Because the class was very well received, we are going to expand that,
Starting point is 00:41:37 and we already have a call out for proposals for people who want to teach that's due in a little over a week. For people who want to teach a two-day class, that would be on that weekend, the 17th and 18th. And then on the 18th, we'll do reception and registration. And then the following weeks, Monday through Friday, will be sessions. So are you thinking multiple parallel class tracks will be happening? Yes, there will be multiple classes. Okay. So, I don't know for sure, and I have some pretty good idea, because we've already talked to some
Starting point is 00:42:12 people. I'm fairly certain Michael is going to be repeating his class again, but that's not committed yet. And then we'll have, and I have, I'm kind of excited about this, because I think we're going to have a good range i'm working to make them not overlap as much as possible okay so um so
Starting point is 00:42:33 i can't really say much at this point because as i said the the proposals aren't due until i think we said the 15th of november and so when those come in we'll think about that it's fairly early to be talking about this already It's fairly early to be talking about this already, but when we go to registration, I want to have all the classes already ready to go. So when you can register for the conference itself, the classes are going to be there. So we kind of have to decide this stuff pretty early on. But yes, and I've also signed contracts with all the hotels for hotel blocks for the next two years. Wow.
Starting point is 00:43:07 Oh, okay. So, yes, planning is underway. Already trying to build on what we've got. As you know, C++ Now is capped. It's always 150 attendees. It's not going to grow. We've made that decision that at that venue, that's the size we want it to be. But CppCon, I'm trying to look forward to a lot of growth there.
Starting point is 00:43:32 So I'm excited about that, and I'm kind of trying to build on that and think about ways to market the conference and let other people know that this is where you want to be. So one thing we talked about when I first had you on the show for episode one was that you were transitioning from working with a nine to pursue a career as a C plus plus instructor. And I wanted to know, how has that transition been for you? Well, I'm loving it. It's really exciting. Um, in fact, when we were talking about this, it made me go back and look at the calendar. And I realized that so far this year, I've given eight weeks of training.
Starting point is 00:44:09 I've attended or run four conferences. I've spoken at three different user groups in New York and Portland and then close to home here. And I attended my first standards committee meeting. And there's just no way I could have done that if I'd had a full-time job, right? So giving up the secure paycheck is kind of scary, right? But I love talking about C++. I love doing training. And there's a lot of, I mean, I'm getting into this and finding out there's companies that I'm working with that do a lot of onboard of new hires.
Starting point is 00:44:49 And so we're looking at kind of standardized training for all new hires. Some companies are looking at making the transition either to 11 or 14, and they want training specifically focused on those new language features. And then a lot of companies are just, hey, we feel like we should have some training in the team every once in a while just to make sure people are building their skills and things like that. And then there are other companies that are looking at a specific situation. And so I'm really excited about it.
Starting point is 00:45:21 I feel like one of the biggest challenges in writing the book and giving the talk about it. I feel like one of the biggest challenges in writing the book and giving the talk about it, there's all this positive stuff going on in C++. There's lots of growth and lots of change. And one of the biggest issues is, how are people going to learn about this? And so I think it's great that we have podcasts, but also we need a lot of training done. There's just a lot of going to conferences and doing it there or doing on-site training and so that's a big need that i see and i'm happy to work to fulfill that very cool yeah i definitely don't want to be
Starting point is 00:45:57 responsible for any training uh go to john don't try to learn from this podcast. So which committee meeting were you able to attend? Was it Kona? Yeah, just got back from Kona. Yeah, and it was my, in a sense, it wasn't really the first meeting because there had been a couple in the Bay Area where, because they were so close, I like went for the afternoon just to kind of observe. But Kona was the first one where i was there all week and i actually i kind of thought i had a pretty good idea but i actually learned an awful lot about how the process works um and it's actually even changed since when i initially observed there's now a new evolution group i have a much better idea about what the evolution groups even mean.
Starting point is 00:46:46 So there's a number of different subgroups in the committee, but there's a group that's just called evolution and a group that's called core, and then there's library evolution and library. And the core groups are the ones where you kind of initially would take a proposal if it's some completely new feature. Now, if all you're talking about is what they call a defect report, you're saying, well, the standard says this, but it's unclear. Does it mean this or does it mean this? Or
Starting point is 00:47:13 maybe it's not unclear. Maybe it clearly means this, but it shouldn't mean this. It's a mistake. So you just take that directly to the library group or to core and say, here's better wording, and they'll look at it. But if you're actually proposing a new feature, like you're saying, oh, I think the language should have lambdas or something like that, then you go to the evolution group and you write your paper about how it would look, what it means, why you want to do it. And in reality, the first time, it's going to get kicked back. Well, you need to think about this, you need, in reality, the first time, if it's, you know, it's going to get kicked back.
Starting point is 00:47:45 They're going to say, well, you need to think about this. You need to look at this. So you write it again and you bring it back. And eventually the evolution people will say, okay, that all looks good. Now go to the core group or the library group, depending on what kind of feature it is. And they will look at the specific wording and make sure the wording is consistent with the rest of the language and stuff like that. So I got to sit in on all these different groups and watch how they work and get a feel for them. And so I didn't really feel like I contributed much this year, but I think I learned enough so that I can be useful in the future. And so I'm looking forward
Starting point is 00:48:23 to more meetings. So if you watch the Grill the Committee video from last year or from this year, the committee members like to insist that they don't go to Hawaii on vacation. They're actually stuck in dark, stuffy rooms the whole time. You got to give us the honest truth here john um so um well i i personally this was my first meeting and although i don't have a boss at a9 anymore i still have a boss and i had to negotiate with her and so the deal was that i would go to the meeting, but I would play hooky a little bit. And we would have, it would be a combined vacation. And since this was my first meeting, I didn't really have any responsibilities.
Starting point is 00:49:11 I was just going to go and observe. So I said, okay. And we stayed a couple extra days afterwards. And I skipped out. I actually only ended up really skipping out on Thursday. And went to the beach. And it was a beautiful beach, and it has these big rocks in it. And it turns out that you really shouldn't try to kick those rocks.
Starting point is 00:49:36 I was trying to navigate around a little traffic, and I accidentally kicked this rock and broke my toe and skinned up my foot. And I suddenly, you know, my first response, my little toe was actually sticking off, not quite 45 degrees, 45 degrees off. And I pushed it back in and I was ready to run in the surf again and I realized, that's going to sting like heck if I have no skin. And, uh, it actually, it was really weird how long it took me to realize
Starting point is 00:50:10 my day at the beach is over just now. And because I need to go, I need to go home. Um, so that paid, I paid for, for skipping out, but I will say the rest of the committee, um, they didn't they you know the sessions start at eight in the morning and after dinner they have more sessions um they talked about for example variant on a couple of nights and no they're really dedicated and the the phrase about windowless room is actually true. The committee was larger than they'd anticipated. So they had to move out of the room they'd initially planned.
Starting point is 00:50:57 And so they put in another room, which, as Herb pointed out, it's technically windowless. That's because the back half of the room completely opens up. The doors open up. Okay. But the problem is that wasn't air conditioned oh and hawaii normally in the 70s the week we were there 88 degrees oh that's too hot yeah yeah and almost 100 humidity or maybe it was i don't know what the humidity was but yeah it was such that part of the reason i only took thursday off is because my wife just said, well, we're not going to do any sightseeing. It's just miserable.
Starting point is 00:51:30 So it was just so hot and muggy. So, no, it's, you know, the committee works hard. They really do. I was really impressed. I felt bad by taking off one day. But most of the other people were there even people who brought their wives were there as i said all day long and then went to evening events so that was um and i suspect kona is probably your you know worst case scenario for that because i think
Starting point is 00:51:58 the next meeting's in jacksonville florida which is jacksonville is not really a big tourist area so florida sounds fun but it's jack Jacksonville's not really a tourist area. Yeah, it's not Disney World. It's a, yeah. So I, yeah. I can, I can verify. It's, it's, it's a lot of, it's a lot of work. It was a beautiful, beautiful place, you know, easy on the eye.
Starting point is 00:52:23 But, but a lot of work got done and, um, it's really gratifying and exciting to see. These are really smart people who are really passionate. I mean, even when they're fighting with each other, they're fighting because they want the language better. They're not fighting because it's like, oh, I don't care. Let's just, you know, let's just do it my way. It's no, let's do it this way because it makes for a better language. And then there's differences of opinion about that. Smart, passionate people working really hard to make C++ better. What's not to love? Sounds good to me. We read the trip reports from STL and from Herb. Was there anything specific you wanted to call
Starting point is 00:53:00 out that you're really excited about from the meeting? I think they kind of got it that there was i mean herb was really pleased that i think the one thing that might not have been in the trip reports because it didn't make a ts um i think and i wasn't there for this but i heard that that there was kind of a breakthrough on contracts and this is one of the things is that for some of the things that made TS, they weren't necessarily particularly controversial, but some of these real agreement had to be made
Starting point is 00:53:32 for them to move forward, and some kind of compromise or some kind of agreement has reached. So, real forward progress. For some of these, it was just a matter of time, but for others it really was, you know, we had to reach an understanding about moving forward. And I think contracts kind of, I don't think it was discussed much in the trip reports,
Starting point is 00:53:51 but I think that's also something that kind of moved forward a little bit. So I'm not really even sure what all's in that proposal, but I think that it's, again, a quality of educating programmers about how to think about code. And any language support you get for contracts, I think, is great. Because I think contracts is a really important way of thinking about code. Right. That's another talk I still need to watch from the last conference. Someone gave a talk on that, right?
Starting point is 00:54:22 Was that Gabby? I know Gabby did a talk on that, right? Was that Gabby? I know Gabby did a talk on modules, right? Yeah, I thought someone else gave a talk on contracts from the last conference also. Well, John Lakos, I think, may have also talked about contracts as well. He talks about, yeah, I think in this one he was talking about, I'm not sure what the title of his talks is but I really enjoy his talks he's really talking about better ways to think about
Starting point is 00:54:53 code and yeah I'll have to look for that one John is there anything else you wanted to share before we let you go well no just again thank you very much for having me on and thank you guys so much for contributing to the discussion
Starting point is 00:55:08 about C++, helping to build the community. I'm very, as I had said earlier, I'm really excited about being part of the C++ community. It seems like it's a lot of people who are very professional, treat each other well.
Starting point is 00:55:24 We all recognize that what we're about It's a lot of people who are very professional, treat each other well. We all recognize that what we're about is C++. Writing programming really in any language is very challenging. And with C++, we've accepted that we're going to push performance just as hard and as fast as we can and also look for you know portability and reliability and all these other things so it's it's a really hard thing and that's why we share with each other about how to do it because that you know we're all in this together in a sense right john where can people contact you if they're interested for your training services um so the email for that is just jonjohn at cpp.training. The top level domain is training.
Starting point is 00:56:11 Wow. Yeah. That's pretty cool. It's a good URL. Well, I wish I had a website and all sorts of stuff, but I actually, it's kind of great that I've been so busy
Starting point is 00:56:21 I haven't had time to do that. So that's a good thing um but i don't really have a you know a website i can point at people but the but i do have the domain and the email works so send it send it there and you are on twitter also yeah i can be reached on twitter or you can i mean if you you can send it john at cppcon.org or cppnow.org i'm pretty easy to i'm pretty easy to contact if you want to get a hold of me. Okay. Okay.
Starting point is 00:56:49 John, thank you so much for your time again. Thanks for joining us. Thank you. Thank you, Bob. Thanks so much for listening as we chat about C++. I'd love to hear what you think of the podcast. Please let me know if we're discussing the stuff you're interested in, or if you have a suggestion for a topic, I'd love to hear that also.
Starting point is 00:57:04 You can email all your thoughts to feedback at cppcast.com. I'd also appreciate if you can follow CppCast on Twitter and like CppCast on Facebook. And of course, you can find all that info and the show notes on the podcast website at cppcast.com. Theme music for this episode is provided by podcastthemes.com.

There aren't comments yet for this episode. Click on any sentence in the transcript to leave a comment.