Skip to content

Commit

Permalink
add credits in three places for copied code.
Browse files Browse the repository at this point in the history
  • Loading branch information
jlapeyre committed Dec 14, 2014
1 parent a187f04 commit ee8edce
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/PermPlain.jl
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ function permpower{T<:Real}(p::AbstractVector{T}, n::Integer)
end

# Compute power of permutation. Both input and output are PCYC
# see pari perm.c
# Translated from pari perm.c
# Careful of degeneracy, and empty array may be returned.
function permpower{T<:Real}(cyc::AbstractArray{Array{T,1},1}, exp::Integer)
r = 1
Expand Down Expand Up @@ -704,6 +704,7 @@ end
cycleprint(v::Array) = cycleprint(STDOUT,v)
permarrprint(v::Array) = permarrprint(STDOUT,v)

# Copied from Base string.jl
function pprint_to_string(printfunc::Function, xs...)
s = IOBuffer(Array(Uint8,isa(xs[1],String) ? endof(xs[1]) : 0), true, true)
truncate(s,0)
Expand Down

0 comments on commit ee8edce

Please sign in to comment.