$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Christian Mazakas (christian.mazakas_at_[hidden])
Date: 2024-12-19 15:30:12
The case against a free function gets a lot stronger once you remember that
optional in C++ still supports unchecked accesses with trivial syntax and
that
the most ergonomic and safe way to actually use it is via something like
this:
users.find(user_id).map([](auto& user) { user.status = deactivated;
return user; });
Were this a free function, a user wouldn't be able to create this nice
fluent interface
that users, by and large, seem to actually like.
- Christian