Get rid of the old Set constructor. #5910

Closed
wants to merge 1 commit into
from

Projects

None yet

2 participants

@dcjones
The Julia Language member

Can we just drop this? It's not actually backwards compatible and pretending it is just introduces subtle bugs when xs happens to be of length 1.

@dcjones
The Julia Language member

I'm finding the Set constructor change to be a very severe one. I've so far managed to keep Gadfly and other packages compatible with 0.2 and 0.3 without maintaining separate branches, but I may have to give up on that now. I don't see a way to construct sets now that works consistently on both 0.2 and 0.3.

@JeffBezanson
The Julia Language member

Yes, I fully acknowledge that this is a pretty extreme breaking change. I really think it has to be done though. I will make your suggested change along with the needed test change.

@JeffBezanson
The Julia Language member

You could go through your own set constructor, such as

set(T, xs...) = union!(Set{T}(), xs)

That will work in both versions.

@dcjones
The Julia Language member

Thanks. I do agree that the change was for the best, just mildly annoying in the short term.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment