Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
dminik
10 months ago
|
parent
|
context
|
favorite
| on:
The repercussions of missing an Ampersand in C++ a...
The easiest* solution would be to do what rust does. You need to use & on both sides and error out on mismatch. Eg.
fn foo(bar: &Bar) { ... }
bar(&Baz)
* This would be a breaking change, so a non-starter.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search:
fn foo(bar: &Bar) { ... }
bar(&Baz)
* This would be a breaking change, so a non-starter.