On Wednesday, April 15, 2015 at 11:08:27 AM UTC-7, Steven G. Johnson wrote: > > On Wednesday, April 15, 2015 at 10:31:46 AM UTC-4, Seth wrote: >> >> 1) is getting Pair into 0.3 something that Compat.jl should handle, or >> should it be a request to get it backported to the main 0.3 build? >> > > Maybe it could go into Compat. But isn't Pair mainly useful when you have > the nice a => b syntax for Pair(a,b)? > > I'm using it because it provides a Base-supported "native" type that I can use for graph edges (source and dest vertices are the elements of the pair). The => construct is just an added bonus. In 0.3 I could default to my own custom datatype, but it'd be nice if Pair were available in earlier versions.
2) what's the best way to determine the version number that introduced Pair >> in 0.4? (I've tried git bisect but couldn't get a definitive answer.) This >> would be the approach I'd take immediately: to have the old type available >> if the version of Julia running didn't support Pair. >> > > I would look at git blame on the base/exports.jl file, to see when Pair > was exported. That turns up this commit: > > > https://github.com/JuliaLang/julia/commit/034b8f5599c3dcd3e770ba8af3a9c28ef2497532 > > To turn this into a version number, see the little shell script on the > Compat.jl page -- it produces 0.4.0-dev+818 for this commit. > Thanks. I recall doing something similar a while back but couldn't remember the precise steps.
