Skip to content
This repository has been archived by the owner on Dec 4, 2017. It is now read-only.

chore: rename Elvis to safe navigation operator #1139

Closed
wants to merge 1 commit into from

Conversation

Foxandxss
Copy link
Member

@Foxandxss Foxandxss commented Apr 22, 2016

Here is the needed rename. I decided not to capitalize "Safe" in any case because I don't like how the text flows in that case.

@kwalrath I checked the Dart part, I don't see any difference on both TS and Dart guides after the changes.

Closes angular/angular#6387

@Foxandxss
Copy link
Member Author

I also updated the cheatsheet, better now than forget later :)

angular/angular#8196

.callout.is-helpful
header Dart difference: ?. is a Dart operator
:marked
The Elvis operator (`?.`) is part of the Dart language.
The safe navigation operator (`?.`) is part of the Dart language.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's not the name we've used in Dart, but I can live with it.

(For the curious: The Dart spec & language tour tend to avoid using a name for it, although the language tour does once call it conditional member access.)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mind changing it for something different, not a problem :)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still better name than no name I guess.

@kwalrath
Copy link
Contributor

LGTM!

@naomiblack
Copy link
Contributor

Can you provide context for why we are making this change? @IgorMinar prefers the shorter "Elvis operator", so I'd like to understand the change.

@IgorMinar
Copy link
Contributor

Where does the need to rename this operator come from?

@Foxandxss
Copy link
Member Author

My bad. Ward asked me to, but there are the issues for it:

angular/angular#6387

And here: angular/angular#791 (comment)

@IgorMinar
Copy link
Contributor

I see. Yeah. let's go ahead and rename. Thanks for making the PR. Can you please reference the other issues via Closes #... thanks!

@Foxandxss
Copy link
Member Author

Foxandxss commented Apr 22, 2016

Can I reference PRs in other repo here with that? On the other hand I created a PR at angular repo (to rename the cheatsheet too) which closes the open issue there.

EDIT: Seems like I can, although the other PR should be merged I guess.

@wardbell
Copy link
Contributor

Thanks Jesus. Merging.

@wardbell wardbell closed this in 4097c67 Apr 23, 2016
@wardbell wardbell deleted the chore/noelvis branch April 23, 2016 21:24
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants