You need to pass a variable containing a Symbol. Try write = :write
On Mon, Mar 24, 2014 at 10:46 PM, J Luis wrote:
> The doc of getfield says
>
> getfield(*value*, *name::Symbol*)
>
> Extract a named field from a value of composite type. The syntax a.b calls
> getfield(a, :b), and the syntax a
The doc of getfield says
getfield(*value*, *name::Symbol*)
Extract a named field from a value of composite type. The syntax a.b calls
getfield(a, :b), and the syntax a.(b) calls getfield(a, b).
but when I try the a.(b) variation, it errors (or it's me who errors?)
julia> gmt_modules.write
"?O"