From 6fc69c89ebef9e8c261d3d887adf96434955ddf7 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Tue, 28 Jun 2022 09:23:05 -0400 Subject: [PATCH] Fix https://github.com/SciML/SciMLBook/issues/64 --- _weave/lecture03/sciml.jmd | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/_weave/lecture03/sciml.jmd b/_weave/lecture03/sciml.jmd index 2be88d48..bc1567a8 100644 --- a/_weave/lecture03/sciml.jmd +++ b/_weave/lecture03/sciml.jmd @@ -174,16 +174,16 @@ initial `W` and `b` matrices (according to the `glorot_uniform` distribution for The last portion might be new. This is known as a **callable struct**, or a functor. It defines the dispatch for how calls work on the struct. As a quick -demonstration, let's define a type `A` with a field `x`, and then make instances +demonstration, let's define a type `MyCallableStruct` with a field `x`, and then make instances of `A` be the function `x+y`: ```julia -struct A +struct MyCallableStruct x end -(a::A)(y) = a.x+y -a = A(2) +(a::MyCallableStruct)(y) = a.x+y +a = MyCallableStruct(2) a(3) ```