Posts

Showing posts from July, 2018

Microsoft's Noexcept Code Throws Exceptions

Image
I've not dug into this one fully yet, I'm mid-stride on what's going on, however the stack has unspooled me to this location having thrown a read access violation... But can you see the problem here?  I'm in Microsoft's xstring, as far as I'm concerned this is from my using std::string or std::ostringstream, the function is decorated "noexcept" yet its throwing an exception! I find this mind bendingly annoying, not least as under GCC & clan on Linux it runs perfectly fine! So, this is "Unhandled exception thrown: read access violation" in xstring _Equal which is decorated noexcept... Time to format c: and never use Windows I think.

C++ : Coding Standards by Example #1 (with Boost Beast)

Image
Today I've spent sometime doing a little different video, rather than just play about in code, whilst I played about I made a video of the time I had... Here is it... We cover: C++ Coding Standards Structured Programming Functional Programming Encapsulation Object Orientated Programming Building the Boost Libraries (1.67.0) Visual Studio 2017 Static Linking And generally spend time seeing how I turn gobble-de-gook code into something usable and maintainable against my own Coding Standards. Get the code yourself here:  https://github.com/Xelous/boostBeast

That Moment...

That moment you get half an hour into watching Brad Pitt in War Machine and the wife suddenly asks.... "Do you know him?" "Who?" "The actor!" "Which actor?" "Him with the grey hair?" "The General?" "Yes" "Brad Pitt" "Fuck off, that's not Brad Pitt" I gave up.

C++ : Copy Constructor versus Ignorance

Image
I've spent a bit of time reviewing someone else's code recently and I've come to an impasse with them, so they have a lot of code which will take some standard container, and the code doesn't just initialise the local copy from the passed in reference... No it'll iterate over the list of elements adding them to the class version. I have picked fault with this, it's not RAII, it looks ugly and if you're threading you can create your class instance and the member is empty or in a partially filled state before the loop within the constructor is finished... I highlight this in red below... My solution?  Just initialise the member from the reference - see the green highlight in the code below. My results from the timing below? These times are "microseconds" so tiny... But with just constructing from the existing reference we always get a lower time, quicker code... Running this test 30,000 times, trying it in different orders and with maps of upto 1000

Preach at the Bar?

Image
Oh its been a long hard fortnight, delivery of project at work and the World Cup took up most of the last week, my cars (yes both of them) have cost me a total of £1,100 so far and one of them is still broke... Hence I'm broke. However, I've been working on a project this very evening and whilst doing so I spotted something rather odd. You might have thought the Preacher was busy sorting out the festivities at PreachCon , however, I think he's been moonlighting on us... No he's not been playing a game other than Warcraft... Oh no... He's literally IN another game... Take a look... From NeebsGaming's video of Drunken Bar Fight ... Uncanny Valley or what mate! That's the Preach!  No-one knows where Ghosty is though...

I'm very emotional

Image

My Three Lions 2018

Image
Being English, specifically an avid supporter of English Football this week is extremely hard to bear, the hope, the wish, the fear the turbid mix on the street, wafting on the radio airwaves and in nearly every news report. I love English football, the agony, the pleasure, that moment the wife storms out the room declaring "I'm stopping watching this" only to see here peeping around the door-frame thirty seconds later. We love you England, we do. And I find a tear in my eye whenever I think back to that warm summer of '96 as here in Nottingham we saw the Turkish team play at the City Ground and the hurt that followed. I stand up to be counted.  I am English.  We are United.  We will play.  I hope they can win. But whatever the weekend brings, we still have our Lions, three of them, proud and loud. Hear Us Roar.

Trade... Post Brexit....

Lets get serious, when the UK leaves the EU there's going to be huge ramifications to our trade... But I think there's a solution... TRUMP... Oi, Trump.. We want a free-trade agreement with Chichester... Our reciprocation?.... Well we'll consider giving you this.... https://www.bbc.co.uk/news/video_and_audio/headlines/44703928/declaration-of-independence-found-in-chichester-archives

Is It Filmable? Ready Player One

Image
Quite controversially, amongst the fans of the book, I really liked the film called Ready Player One... See what I did there?  I separated the book from the film... They have the same name in the sense that we call a Guinea Pig a pig... But they're not pigs and despite borrowing a few parts this film is not of the much better book. Why the divergence?  Well, simply put the appeal would have been too niche, the geek chique of even knowing about RP1 is far below the radar scatter detection level of a Hollywood film executive or producer squad, and sadly gone are the games of rock or pop stars funding a film just "so they can see it" (*cough* shout out to George Harrison there). The book therefore does not have a main stream enough appeal to warrant the investment as it would likely not make any return, where have we heard this before? Putting aside human interest, the logistics...  Technically the story told in the produced film is far more technically and spectacular with