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

Update Golumns package #48

Merged
merged 1 commit into from
Aug 28, 2016
Merged

Conversation

grantseltzer
Copy link
Contributor

I found an issue in golumns causing some other use cases to panic, didn't have the issue with dbxcli, but I definitely think it's important to vendor in this change.

@@ -62,5 +63,9 @@ func numberOfRows(numberOfRows, numberOfNames int) int {
}

func reverse(input []int) []int {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why not just use sort.Reverse instead of your own helper? https://golang.org/pkg/sort/#Reverse

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It certainly is a little sloppy to have a helper function do it, but I chose it for readability reasons. The sort.Reverse function requires an interface type, so I'd have to do conversions with sort.IntSlice which I wasn't very happy with. I'll take another look to see if it's less complicated than I originally thought it was.

@diwakergupta
Copy link
Collaborator

Will go ahead and merge, but Golumns should just use stdlib where possible.

@diwakergupta diwakergupta merged commit 7af4271 into dropbox:master Aug 28, 2016
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

Successfully merging this pull request may close these issues.

2 participants