Damus
Matt profile picture
Matt
@CodingInLondon

C++ engineer writing about things 🔋🔑

Relays (12)
  • wss://nostr-relay.wlvs.space – read & write
  • wss://relay.snort.social – read & write
  • wss://nostr.bitcoiner.social – read & write
  • wss://relay.damus.io – read & write
  • wss://relay.nostr.info – read & write
  • wss://nostr-01.bolt.observer – read & write
  • wss://relayer.fiatjaf.com – read & write
  • wss://nostr1.tunnelsats.com – read & write
  • wss://atlas.nostr.land – read & write
  • wss://eden.nostr.land – read & write
  • wss://nostr-pub.wellorder.net – read & write
  • ws://100.69.75.120:4848 – read & write

Recent Notes

Matt profile picture
C++ nugget:

The C++ compiler assumes that if two pointers have different types, they must have different addresses.

This is not always true: in HFT you often pre-allocate memory then create/destroy objects with placement new.

To avoid subtle bugs: std::launder
naddr1qvzq...
Matt · 1w
Looks like it does not.
Matt profile picture
Reading “Beyond Democracy”…

An alternative for France: instead of having a single elected government that changes every five years, we could have 18 stable governments, one for each region, each one with its own laws and its own taxes.

Citizens would be free to choose which region they want to live in and which government they want to pay for.

Competition between governments would improve the quality of the services provided to citizens.
Matt profile picture
Talks were high quality, very informative with technical details from the energy industry world, in particular I was happy to learn:

- why the French nuclear fleet has surplus capacity and how this capacity was estimated.
- how mining differs from AI, and what are the unique properties of each type of compute.
- how the Iberian blackout happened step by step
- the specific regulatory reasons that still hinder mining as flexible load in Europe despite the obvious need.

Can’t wait for the upload of the videos.


1❤️1
freemadeira · 3w
Talks coming very soon đź‘€
Matt profile picture
C: how do we store a string? let’s use a char*, it’s efficient.

“But it’s dangerous! What it is passed around and outlives the original string?”

C++98: let’s use a std::string instead.

“But it’s expensive to copy and return”

C++11: move semantics.

“But it’s not backwards compatible with char * without a copy!”

C++17: std::string_view

“But it’s dangerous! What it is passed around and outlives the original string?”

Matt profile picture
Hitting usage limits with Claude is like starting a very long C++ build.

It forces you to stop and think about what you've done so far, take a walk outside and fix the next bugs in your head.