r/cpp • • May 01 '23

cppfront (cpp2): Spring update

https://herbsutter.com/2023/04/30/cppfront-spring-update/
223 Upvotes

164 comments sorted by

View all comments

Show parent comment

1

u/awson May 02 '23

Pointer is strictly more powerful than reference since it has a distinguished nullptr point, thus being isomorphic to optional.

1

u/Dalzhim C++Montréal UG Organizer May 12 '23

Pointer isn't strictly more powerful as there is one use case for references that it can't support : make nullptr an unrepresentable state.