Skip to content

Commit 8a0064d

Browse files
committed
Also remove dynamic dispatch from GeneralLazyBifferCache
1 parent 9a12862 commit 8a0064d

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ new caches on demand when they are required. The function `f` generates the cach
247247
for the type of `u`, and subsequent indexing reuses that cache if that type of `u` has
248248
already ben seen.
249249

250-
Note that `LazyBufferCache` does cause a dynamic dispatch and its return is not type-inferred.
250+
Note that `GeneralLazyBufferCache`'s return is not type-inferred.
251251
This means it's the slowest of the preallocation methods, but it's the most general.
252252

253253
### Example

docs/src/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ new caches on demand when they are required. The function `f` generates the cach
242242
for the type of `u`, and subsequent indexing reuses that cache if that type of `u` has
243243
already been seen.
244244

245-
Note that `LazyBufferCache` does cause a dynamic dispatch and its return is not type-inferred.
245+
Note that `GeneralLazyBufferCache`'s return is not type-inferred.
246246
This means it's the slowest of the preallocation methods, but it's the most general.
247247

248248
### Example

src/PreallocationTools.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ correct using things like function barriers, then this is a general technique th
234234
is sufficiently fast.
235235
"""
236236
struct GeneralLazyBufferCache{F <: Function}
237-
bufs::Dict # a dictionary mapping types to buffers
237+
bufs::Dict{Any, Any} # a dictionary mapping types to buffers
238238
f::F
239239
GeneralLazyBufferCache(f::F = identity) where {F <: Function} = new{F}(Dict(), f) # start with empty dict
240240
end

0 commit comments

Comments
 (0)