Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

subdoc: push_front/push_back => push_first/push_last #28

Closed
mnunberg opened this issue Feb 26, 2016 · 7 comments
Closed

subdoc: push_front/push_back => push_first/push_last #28

mnunberg opened this issue Feb 26, 2016 · 7 comments

Comments

@mnunberg
Copy link
Contributor

The former names C++ functions, and it's not immediately clear what the "front" and "back" actually mean (I'll tell you that these were confusing to me when I was first learning C++).

I believe first/last more intuitively reflects the location of where the items are added to. We can even do 'push_left' and 'push_right'...

@mnunberg
Copy link
Contributor Author

mnunberg commented Mar 2, 2016

Upon further consideration, we might use:

  • push_at
  • push_right
  • push_left

@brett19
Copy link
Contributor

brett19 commented Mar 2, 2016

I really like push_at, but the push_left and push_right are a bit icky.

@simonbasle
Copy link
Contributor

@brett19 @mnunberg wasn't there a vote for that naming? what was the result? can we commit to anything?

@brett19
Copy link
Contributor

brett19 commented Mar 15, 2016

ArrayAppend, ArrayPrepend were the winners, with PushFront, PushBack having similar support but falling in second.

@mnunberg
Copy link
Contributor Author

So:

array_append
array_prepend
array_insert
array_addunique

Good?

On Mar 15, 2016, at 9:39 AM, Brett Lawson notifications@github.com wrote:

ArrayAppend, ArrayPrepend were the winners, with PushFront, PushBack having similar support but falling in second.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#28 (comment) #28 (comment)

@simonbasle
Copy link
Contributor

Sounds good to me!

@jeffrymorris
Copy link
Contributor

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants