We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
setfield
julia> versioninfo() Julia Version 0.5.2 Commit f4c6c9d (2017-05-06 16:34 UTC) Platform Info: OS: Windows (x86_64-w64-mingw32) CPU: Intel(R) Core(TM) i7-4500U CPU @ 1.80GHz WORD_SIZE: 64 BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell) LAPACK: libopenblas64_ LIBM: libopenlibm LLVM: libLLVM-3.7.1 (ORCJIT, haswell) julia> type T1 field1::Array{AbstractFloat,2} end julia> t1i1 = T1([0. 0.]) T1(AbstractFloat[0.0 0.0]) julia> setfield!(t1i1, :field1, [1. 1.]) ERROR: TypeError: setfield!: expected Array{AbstractFloat,2}, got Array{Float64,2} julia> t1i1.field1 = [1. 1.] 1×2 Array{Float64,2}: 1.0 1.0
The text was updated successfully, but these errors were encountered:
Dup of #16195
Sorry, something went wrong.
No branches or pull requests
The text was updated successfully, but these errors were encountered: