Skip to content

Commit

Permalink
fix documentation for names -> fieldnames rename
Browse files Browse the repository at this point in the history
  • Loading branch information
jakebolewski committed Mar 16, 2015
1 parent 171a2af commit 06fdd7f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions doc/manual/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -403,11 +403,11 @@ However, the value for ``baz`` must be convertible to :class:`Int`:
ERROR: InexactError()
in Foo at no file

You may find a list of field names using the ``names`` function.
You may find a list of field names using the ``fieldnames`` function.

.. doctest::

julia> names(foo)
julia> fieldnames(foo)
3-element Array{Symbol,1}:
:bar
:baz
Expand Down
4 changes: 2 additions & 2 deletions doc/stdlib/base.rst
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ Types

.. doctest::

julia> structinfo(T) = [zip(fieldoffsets(T),names(T),T.types)...];
julia> structinfo(T) = [zip(fieldoffsets(T),fieldnames(T),T.types)...];

julia> structinfo(StatStruct)
12-element Array{(Int64,Symbol,DataType),1}:
Expand Down Expand Up @@ -903,7 +903,7 @@ Reflection
Get an array of the names exported by a module, with optionally more module
globals according to the additional parameters.

.. function:: names(x::DataType)
.. function:: fieldnames(x::DataType)

Get an array of the fields of a data type.

Expand Down

0 comments on commit 06fdd7f

Please sign in to comment.