Merge pull request #400 from IsaacTay/patch-1

updated loadparams! function
This commit is contained in:
Mike J Innes 2018-09-17 00:03:07 +01:00 committed by GitHub
commit b3a08baf55
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,7 +54,7 @@ function loadparams!(m, xs)
for (p, x) in zip(params(m), xs)
size(p) == size(x) ||
error("Expected param size $(size(p)), got $(size(x))")
copy!(data(p), data(x))
copyto!(data(p), data(x))
end
end