@@ -76,14 +76,13 @@ trait objects in detail in Chapter 18.) Using trait objects lets us treat each
7676of the anonymous futures produced by these types as the same type, because all
7777of them implement the ` Future ` trait.
7878
79- > Note: In the Chapter 8 section [ Using an Enum to Store Multiple
80- > Values] [ enum-alt ] <!-- ignore --> , we discussed another way to include multiple
81- > types in a ` Vec ` : using an enum to represent each type that can appear in the
82- > vector. We can’t do that here, though. For one thing, we have no way to name
83- > the different types, because they are anonymous. For another, the reason we
84- > reached for a vector and ` join_all ` in the first place was to be able to work
85- > with a dynamic collection of futures where we only care that they have the
86- > same output type.
79+ > Note: In [ Using an Enum to Store Multiple Values] [ enum-alt ] <!-- ignore --> in
80+ > Chapter 8, we discussed another way to include multiple types in a ` Vec ` :
81+ > using an enum to represent each type that can appear in the vector. We can’t
82+ > do that here, though. For one thing, we have no way to name the different
83+ > types, because they are anonymous. For another, the reason we reached for a
84+ > vector and ` join_all ` in the first place was to be able to work with a dynamic
85+ > collection of futures where we only care that they have the same output type.
8786
8887We start by wrapping each future in the ` vec! ` in a ` Box::new ` , as shown in
8988Listing 17-16.
0 commit comments