hachyderm.io is one of the many independent Mastodon servers you can use to participate in the fediverse.
Hachyderm is a safe space, LGBTQIA+ and BLM, primarily comprised of tech industry professionals world wide. Note that many non-user account types have restrictions - please see our About page.

Administered by:

Server stats:

8.9K
active users

In retrospect, I wish C++ used the term "alias" instead of "reference" to be very clear that a pointer or similar underlying mechanism, including storage, is not necessary.

"It is unspecified whether or not a reference requires storage."

eel.is/c++draft/dcl.ref#4

The issue now (and not really C++'s fault) is that people coming from a language like Java hear "reference" and think it works the same way in C++ as it does in Java. Especially reference parameters. 😔

eel.is[dcl.ref]

Selected slides from my presentation comparing references in C++ and Java. ☝️

#cpp#cplusplus#java
Sean Murthy

An illustration, a couple of exercises, and an example comparing references in C++ and Java (and Python). ☝️

(This is also when I wish more students were on Mastodon/Fediverse. I don't know how but we need to collectively work on that.)

#cpp#cplusplus#java