JuliaAttic / Markdown.jl

Markdown parsing for Julia
Other
40 stars 11 forks source link

Transitional synthax for 'Dict' #20

Closed juliangehring closed 9 years ago

juliangehring commented 9 years ago

Adapt the construction of the Dict to a synthax that is compatible with both julia 0.3 and 0.4. This avoids the startup warning WARNING: deprecated syntax "[a=>b, ...]" at /Users/julian/.julia/v0.4/Markdown/src/render/terminal/formatting.jl:4. in julia 0.4/devel.

MikeInnes commented 9 years ago

Thanks for having a go at this, but I'm not sure if it's the right thing to accept it, since Markdown.jl doesn't officially support 0.4 anyway. In 0.4 you can just do using Base.Markdown to use the built-in Markdown parser (which is exactly the same code).

An easy way to do this would be

if VERSION < v"0.4-"
  using Markdown
else
  using Base.Markdown
end
hayd commented 9 years ago

This is now fixed in master via #23

https://github.com/one-more-minute/Markdown.jl/blob/ae6064d8d506efb0ad4ff6c87ff506d94efd51d6/src/render/terminal/formatting.jl#L5-L18