Skip to content

Commit 627091f

Browse files
committed
Fix docs rendering
1 parent 1103d14 commit 627091f

File tree

3 files changed

+8
-14
lines changed

3 files changed

+8
-14
lines changed

docs/src/types.md

+4-13
Original file line numberDiff line numberDiff line change
@@ -48,16 +48,7 @@ Equations are specified as binary trees with the `Node` type, defined
4848
as follows:
4949

5050
```@docs
51-
Node{T}
52-
```
53-
54-
There are a variety of constructors for `Node` objects, including:
55-
56-
```@docs
57-
Node(::Type{T}; val=nothing, feature::Integer=nothing) where {T}
58-
Node(op::Integer, l::Node)
59-
Node(op::Integer, l::Node, r::Node)
60-
Node(var_string::String)
51+
Node
6152
```
6253

6354
When you create an `Options` object, the operators
@@ -69,19 +60,19 @@ When using these node constructors, types will automatically be promoted.
6960
You can convert the type of a node using `convert`:
7061

7162
```@docs
72-
convert(::Type{Node{T1}}, tree::Node{T2}) where {T1, T2}
63+
convert(::Type{AbstractExpressionNode{T1}}, tree::AbstractExpressionNode{T2}) where {T1, T2}
7364
```
7465

7566
You can set a `tree` (in-place) with `set_node!`:
7667

7768
```@docs
78-
set_node!(tree::Node{T}, new_tree::Node{T}) where {T}
69+
set_node!
7970
```
8071

8172
You can create a copy of a node with `copy_node`:
8273

8374
```@docs
84-
copy_node(tree::Node)
75+
copy_node
8576
```
8677

8778
## Graph-Like Equations

src/Equation.jl

+4
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,10 @@ cos(sin(x1) + {x1}) * {(sin(x1) + {x1})}
160160
161161
Note how the `{}` indicates a node is shared, and this
162162
is the same node as seen earlier in the string.
163+
164+
This has the same constructors as `Node{T}`. Shared nodes
165+
are created simply by using the same node in multiple places
166+
when constructing or setting properties.
163167
"""
164168
mutable struct GraphNode{T} <: AbstractExpressionNode{T}
165169
degree::UInt8 # 0 for constant/variable, 1 for cos/sin, 2 for +/* etc.

src/base.jl

-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ import Base:
2525
import Compat: @inline, Returns
2626
import ..UtilsModule: @memoize_on, @with_memoize, Undefined
2727

28-
2928
"""
3029
tree_mapreduce(
3130
f::Function,

0 commit comments

Comments
 (0)