std::exchange Patterns: Fast, Safe, Expressive, and Probably Underused

Slack Tracking in V8

The Fresh Smell of ransomed coffee

Issue #11

9/25/2020

Or subscribe using...
Github icon for OAuth via Github Google icon for OAuth via Google
A Byte of Coding Issue #11
TGIF!
Don't know why I still get excited about Fridays. I can make my own work schedule, so the weekend isn't really the weekend, but I guess it's just been ingrained in my mind from school. Anyways here's the issue.
Donate Here

std::exchange Patterns: Fast, Safe, Expressive, and Probably Underused

Published: 25 September 2020
Tags: cpp


 If you're unfamiliar with std::exchange, it basically just takes an object value, replaces it with a new value, and then returns the old object value. Does that sound familiar? Well if it doesn't, Ben Deane's article does an excellent job of giving some good example use cases for exchange, including iterators and passing variables in a multi-thread environment. Ben also compares it to swap and move.

Read Full Article

Slack Tracking in V8

Published: 24 September 2020
Tags: v8, javascript


"Slack tracking is a way to give new objects an initial size that is larger than what they may actually use, so they can have new properties added quickly. And then, after some period of time, to magically return that unused space to the system". This is useful for JavaScript because it doesn't have static classes. Michael Stanton has written an extensive article that dives into how this feature is implemented in the V8 engine, accompanied by lots of code and diagrams.

Read Full Article

The Fresh Smell of ransomed coffee

Published: 25 September 2020
Tags: hacking


The popularity of IoT devices, like smart lights, smart homes, or smart coffee makers, has been growing substantially in recent years. These devices can be fun to use (or frustrating), and convenient, but when they're not very well secured. In this instructional article, Martin Hron presents how he hacked his way into a popular smart coffee maker be reverse engineering and modifying its firmware. Martin covers all the important, and subtle points, making this a very well fleshed out article packed full of information.

Read Full Article
Thanks for your Support! 

This newsletter is provided to you for free, but if you'd like to show your support and help out, you can donate on the Patreon page. It's not necessary, but it lets me know that I'm doing a good job and that you're finding value in the content.
Donate Here






This email was sent to <<Email Address>>
why did I get this?    unsubscribe from this list    update subscription preferences
A Byte of Coding · 750 Fowler St NW · Atlanta, GA 30332-1914 · USA

Stats (updated daily)

Sent: 660

Opens: 374

Clicks: 188

Link Clicks Clicks % Unique Clicks Unique Clicks %
std::exchange Patterns: Fast, Safe, Expressive, and Probably Underused 66 36.07% 48 33.57
Slack Tracking in V8 20 10.93% 17 11.89
The Fresh Smell of ransomed coffee 97 53.01% 78 54.55

Previous

Back to Issues

Next