@LucDanton Yeah, I don't like that, too. It reminded me of node.js. Since I have seen boost::asios coroutine interface I have quite an objection to too many callbacks anyway.
For having used expected a bit, the least that can be said about it is that it’s type-safe, closed-world, C-style error handling. Useful, if not sexy. I wouldn’t mind a Standard one so that it crops up in APIs.
I hope there will be a .value() that does something sensible (e.g. rethrow exceptions and std::exception_ptr, rethrow error codes in std::system_error). So far the proposal handles std::exception_ptr only.
@LucDanton I think there is a value in the proposal. Though, doesn't the proposal go in the total other direction that you shouldn't use the value functions and instead use the callbacks?
@LucDanton Saying that it's "type-safe C-style error handling" is like saying "I did a fantastically type-safe shit today". I guess I don't see why anyone would want C-style error handling regardless of the lack of type-safety.
@bamboon A .value() is useful for getting from the closed world of expected to the exception open world of exceptions. (It doesn’t have to be value though, if we want to still raise a particular bad_unexpected for that one.)
@LucDanton Not at all, when I can make the compiler automatically generate correct code for me. Why waste time reviewing manually-written code instead of just generating correct code?
@BenjaminGruenbaum Even commercial compilers often had bugs, back in the dusty corners. Maybe not so much any more, but certainly did back when I wrote Fortran.
@JerryCoffin that makes sense, I find bugs in JS runtimes pretty much on a semi daily basis and those are some of the most worked on compilers in the world
Filing a bug as a way to contribute back to a project you appreciate is very different from filing 600 bugs to serve as QA for a project that doesn't appreciate the users who aren't Jeff.
How many agree that uniform initialization is non-uniform BS and should only be used for aggregate-initialization and initializer-list-constructors? One guy in the forum stated that the majority of C++ programmers thinks they should use list-initialization wherever possible.
@Loopunroller Without trying to draw a conclusion about exactly what should be used when, I think it's safe to say that the notion of "uniform initialization" was over-sold.
@JerryCoffin Yes, that is a fact by now. The most direct proof of that is std::allocator<>::construct: It can't (shouldn't) use list-initialization. Guess why.
@Puppy It’s not subtyping of the exceptions that I’m concerned with, but subtyping of function types (i.e. I’m sceptical that the compiler can deduce the most useful exception annotations). That being said you did mention optionally inferred annotations.
considering that the vast majority of the language has yet to be decided, I fail to see how it's possible for it to definitively exhibit any particular property
@BartekBanachewicz I didn't write all my C++ code to be impure either. So I don't really see what's different between "I rarely use impurity" and "I rarely use impurity".
For anyone who cares (probably nobody), I am still doing the bathroom & I have to hand over the keys tomorrow. It's 11:30pm & I will probably have to spend another 2 hours here ...
It's not the result of the final program, mostly because they are invoked by operating systems and operating systems don't know how to deal with IO ().
@JerryCoffin take occasional rests are good for health, especially when you are stressed. Also the drive home is about 20 minutes without much traffic ...
why blue collar workers don't do all nighters (unless doing the night shifts) ... I mean the noise level is almost neglectable when there's plenty space between you and the neighbours ...
@BartekBanachewicz ...and there's quite a bit you clearly don't "get" either. What of it? Purity has its points, but it's a tool, not a goal in itself.
@BartekBanachewicz ...or somewhat different. Or not at all different--depending on how much of the code you write in a pure manner. Self-enforced purity can produce the same result as compiler-enforced purity. But as I said: purity is a tool, not a goal in itself.
> The kickee does not have to be in the room at the time they're being kicked (requiring this would allow trolls to prevent being banned by entering a room, quickly saying "TABS ARE BETTER THAN SPACES!!!!one", and immediately leaving the room again before anyone could have taken action).
@JerryCoffin actually... Do you really have such a big gap on your "language awesomeness" list between say, PHP and JS/Ruby/Lua/whatever-non-haskell-language?
> Rarely depicted visually in any of the Terminator media, Skynet's operations are almost exclusively performed by war-machines, cyborgs (usually a Terminator), and other computer systems, with the goal of exterminating the human race.