Skip to content

Commit

Permalink
Remove (c)transpose no-op for Strings and revise associated test.
Browse files Browse the repository at this point in the history
  • Loading branch information
Sacha0 committed Jul 8, 2016
1 parent 060a51c commit 759dba3
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions base/strings/basic.jl
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,6 @@ function length(s::AbstractString)
end
end

transpose(s::AbstractString) = s

## string comparison functions ##

function cmp(a::AbstractString, b::AbstractString)
Expand Down
2 changes: 1 addition & 1 deletion test/strings/basic.jl
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ foobaz(ch) = reinterpret(Char, typemax(UInt32))

@test "a".*["b","c"] == ["ab","ac"]
@test ["b","c"].*"a" == ["ba","ca"]
@test ["a","b"].*["c","d"]' == ["ac" "ad"; "bc" "bd"]
@test ["a","b"].*["c" "d"] == ["ac" "ad"; "bc" "bd"]

# Make sure NULL pointers are handled consistently by String
@test_throws ArgumentError unsafe_string(Ptr{UInt8}(0))
Expand Down

0 comments on commit 759dba3

Please sign in to comment.