KayEss
u/KayEss
I've started a series of tutorial pieces about how the coroutines TS works, that is, how to write code that uses the facilities provided to do interesting things.
So far I've only covered co_return with an intro piece. co_return is split up with a first part talking generally about suspension and uses coroutines to emulate normal function calls, and then a second that makes a lazy function and deals resumption and the coroutine handle.
Next up will be `co_yiel
I'm using Clang 5 to try to learn how to write the control machinery for them. I got my first one working, but that was just a co_return. I've been trying to work on the generator example on p15 before attempting to add co_await support to it.
To start with, the version in the paper doesn't compile as the promise type is missing return_void and unhandled_exception.
Secondly, release builds crash after yielding the first value. I've instrumented it and it happens in the coro.resume() call before f() is re-entered. Debug builds work, but crash at the end with a double free/memory corruption error.
The missing members in the example looks like an errata in the paper (or maybe the
I've started a new library for talking to Postgres servers. At the moment this is built on Boost ASIO with its coroutines support (using Boost coroutine).
The plan is to move on to newer compilers pretty much as fast as possible, but I'm wondering what the use of coroutines together with networking is actually going to look like. I'm expecting that the yield_context instances all go away, but is the general shape of the APIs still going to be relevant, or is it likely to be a complete redesign of the APIs?
The library is here: https://github.com/KayEss/pgasio
Why do we want to base the standard library handling of UTF-8 around char rather than unsigned char? It seems to me that the use of char is highly problematic in that I can't portably read any values outside the range 0 to 127 as the char could be signed or unsigned.
Am I just wrong in this? Would it not have been better to have defined the u8 string literals as producing unsigned char * and to be making the standard library support for utf-8 strings based around std::basic_string<unsigned char>?
What's the right approach to writing portable code that does UTF-8 decoding, or is it only the standard library maintainers who can do this? Is there any way I can portably put
It's Saturday in my time zone and after loading the game this morning there were no new dailies. Tried to restart the game again and the same.
Is it just me, or did this happen to others too?
(This is the expanded TL;DR, even more expansion of the points is in the comments)
There's a lot of griping about GW here, and I'm sure elsewhere. I didn't want to just gripe, I wanted to deconstruct the problems and how the bad decisions in game design seem to come to make up a perfect storm of bad player experience.
Firstly, the adversary that I'm fighting in these battles has a completely different character. I'm no longer playing the odds and hoping for a bit of luck, I'm instead trying to decrypt the script the RNG is using to optimise the outcome of each battle (see "RNG hell" below). This completely changes the character of these battles, and for me at least not in a fun way.
The