Skip to content

Commit df5049d

Browse files
committed
Make pretty take an AbstractString
1 parent 45e5494 commit df5049d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/pretty.jl

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ See [`JSON3.write`](@ref) and [`JSON3.read`](@ref).
5252
"""
5353
pretty(str, ac=AlignmentContext(); kw...) = pretty(stdout, str, ac; kw...)
5454
pretty(out::IO, x, ac=AlignmentContext(); kw...) = pretty(out, JSON3.write(x; kw...), ac; kw...)
55-
function pretty(out::IO, str::String, ac=AlignmentContext(); kw...)
55+
function pretty(out::IO, str::AbstractString, ac=AlignmentContext(); kw...)
5656
buf = codeunits(str)
5757
len = length(buf)
5858
if len == 0

0 commit comments

Comments
 (0)