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

string(x::Symbol) should be String(x::Symbol) #16997

Closed
quinnj opened this issue Jun 17, 2016 · 5 comments
Closed

string(x::Symbol) should be String(x::Symbol) #16997

quinnj opened this issue Jun 17, 2016 · 5 comments
Labels
domain:strings "Strings!" good first issue Indicates a good issue for first-time contributors to Julia Hacktoberfest Good for Hacktoberfest participants

Comments

@quinnj
Copy link
Member

quinnj commented Jun 17, 2016

Just a minor cleanup along with the Stringapalooza party. A good "up-for-grabs" if anyone in particular wants to tackle it.

@kshyatt kshyatt added good first issue Indicates a good issue for first-time contributors to Julia domain:strings "Strings!" labels Jun 20, 2016
@dbeach24
Copy link
Contributor

Dumb question: Where is string(::Symbol) ?

               _
   _       _ _(_)_     |  A fresh approach to technical computing
  (_)     | (_) (_)    |  Documentation: http:https://docs.julialang.org
   _ _   _| |_  __ _   |  Type "?help" for help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.5.0-rc2+1 (2016-08-18 05:47 UTC)
 _/ |\__'_|_|_|\__'_|  |  djcb/bugfix-18073/7cade48 (fork: 1 commits, 6 days)
|__/                   |  x86_64-apple-darwin14.5.0

julia> methods(string)
# 13 methods for generic function "string":
string(dt::Date) at dates/io.jl:18
string(dt::DateTime) at dates/io.jl:5
string(x::Base.Dates.CompoundPeriod) at dates/periods.jl:298
string(id::Base.LibGit2.Oid) at libgit2/oid.jl:69
string(x::BigFloat) at mpfr.jl:853
string(x::BigInt) at gmp.jl:513
string() at strings/basic.jl:10
string(x::Union{Int128,Int16,Int32,Int64,Int8}) at intfuncs.jl:264
string(a::String...) at strings/string.jl:167
string(a::Union{Char,String}...) at strings/string.jl:179
string(s::AbstractString) at strings/basic.jl:11
string{P<:Base.Dates.Period}(x::P) at dates/periods.jl:44
string(xs...) at strings/io.jl:68

@JeffBezanson
Copy link
Sponsor Member

julia> @which string(:x)
string(xs...) at strings/io.jl:68

There's no method just for this case, so I guess this is just about adding a method to String.

@dbeach24
Copy link
Contributor

So, then

String(x::Symbol) = string(x)

is all that this issue is about?

dbeach24 added a commit to dbeach24/julia that referenced this issue Aug 18, 2016
Adds support for String(x::Symbol) = string(x)
dbeach24 added a commit to dbeach24/julia that referenced this issue Aug 20, 2016
Adds support for String(x::Symbol) = string(x)
dbeach24 added a commit to dbeach24/julia that referenced this issue Sep 18, 2016
This is the underlying support for calling String(::Symbol).
Bug fix for issue JuliaLang#16997
dbeach24 added a commit to dbeach24/julia that referenced this issue Sep 18, 2016
This is the underlying support for calling String(::Symbol).
Bug fix for issue JuliaLang#16997
@kshyatt kshyatt added the Hacktoberfest Good for Hacktoberfest participants label Oct 5, 2016
@KristofferC
Copy link
Sponsor Member

I think closed by #16997

@tkelman
Copy link
Contributor

tkelman commented May 26, 2017

this is #16997.

#18152, probably

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:strings "Strings!" good first issue Indicates a good issue for first-time contributors to Julia Hacktoberfest Good for Hacktoberfest participants
Projects
None yet
Development

No branches or pull requests

6 participants