Skip to content

Commit 23515b2

Browse files
rwgkfbusato
authored andcommitted
Fix miscellaneous bugs in documentation. (NVIDIA#2580)
1 parent 973f8b1 commit 23515b2

4 files changed

+17
-18
lines changed

cub/cub/iterator/arg_index_input_iterator.cuh

+11-12
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,8 @@ CUB_NAMESPACE_BEGIN
6464
* indices (forming \p KeyValuePair tuples).
6565
*
6666
* @par Overview
67-
* - ArgIndexInputIteratorTwraps a random access input iterator @p itr of type @p InputIteratorT.
68-
* Dereferencing an ArgIndexInputIteratorTat offset @p i produces a @p KeyValuePair value whose
67+
* - ArgIndexInputIterator wraps a random access input iterator @p itr of type @p InputIteratorT.
68+
* Dereferencing an ArgIndexInputIterator at offset @p i produces a @p KeyValuePair value whose
6969
* @p key field is @p i and whose @p value field is <tt>itr[i]</tt>.
7070
* - Can be used with any data type.
7171
* - Can be constructed, manipulated, and exchanged within and between host and device
@@ -74,7 +74,7 @@ CUB_NAMESPACE_BEGIN
7474
* - Compatible with Thrust API v1.7 or newer.
7575
*
7676
* @par Snippet
77-
* The code snippet below illustrates the use of @p ArgIndexInputIteratorTto
77+
* The code snippet below illustrates the use of @p ArgIndexInputIterator to
7878
* dereference an array of doubles
7979
* @par
8080
* @code
@@ -87,17 +87,16 @@ CUB_NAMESPACE_BEGIN
8787
* cub::ArgIndexInputIterator<double*> itr(d_in);
8888
*
8989
* // Within device code:
90-
* using Tuple = typename cub::ArgIndexInputIterator<double*>::value_type;
91-
* Tuple item_offset_pair.key = *itr;
92-
* printf("%f @ %d\n",
93-
* item_offset_pair.value,
94-
* item_offset_pair.key); // 8.0 @ 0
90+
* cub::ArgIndexInputIterator<double*>::value_type tup = *itr;
91+
* printf("%f @ %ld\n",
92+
* tup.value,
93+
* tup.key); // 8.0 @ 0
9594
*
9695
* itr = itr + 6;
97-
* item_offset_pair.key = *itr;
98-
* printf("%f @ %d\n",
99-
* item_offset_pair.value,
100-
* item_offset_pair.key); // 9.0 @ 6
96+
* tup = *itr;
97+
* printf("%f @ %ld\n",
98+
* tup.value,
99+
* tup.key); // 9.0 @ 6
101100
*
102101
* @endcode
103102
*

cub/cub/iterator/constant_input_iterator.cuh

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,15 +61,15 @@ CUB_NAMESPACE_BEGIN
6161
* @brief A random-access input generator for dereferencing a sequence of homogeneous values
6262
*
6363
* @par Overview
64-
* - Read references to a ConstantInputIteratorTiterator always return the supplied constant
64+
* - Read references to a ConstantInputIterator always return the supplied constant
6565
* of type @p ValueType.
6666
* - Can be used with any data type.
6767
* - Can be constructed, manipulated, dereferenced, and exchanged within and between host and device
6868
* functions.
6969
* - Compatible with Thrust API v1.7 or newer.
7070
*
7171
* @par Snippet
72-
* The code snippet below illustrates the use of @p ConstantInputIteratorTto
72+
* The code snippet below illustrates the use of @p ConstantInputIterator to
7373
* dereference a sequence of homogeneous doubles.
7474
* @par
7575
* @code

cub/cub/iterator/counting_input_iterator.cuh

+2-2
Original file line numberDiff line numberDiff line change
@@ -67,14 +67,14 @@ CUB_NAMESPACE_BEGIN
6767
* @brief A random-access input generator for dereferencing a sequence of incrementing integer values.
6868
*
6969
* @par Overview
70-
* - After initializing a CountingInputIteratorTto a certain integer @p base, read references
70+
* - After initializing a CountingInputIterator to a certain integer @p base, read references
7171
* at @p offset will return the value @p base + @p offset.
7272
* - Can be constructed, manipulated, dereferenced, and exchanged within and between host and device
7373
* functions.
7474
* - Compatible with Thrust API v1.7 or newer.
7575
*
7676
* @par Snippet
77-
* The code snippet below illustrates the use of @p CountingInputIteratorTto
77+
* The code snippet below illustrates the use of @p CountingInputIterator to
7878
* dereference a sequence of incrementing integers.
7979
* @par
8080
* @code

cub/cub/iterator/transform_input_iterator.cuh

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ CUB_NAMESPACE_BEGIN
6161
* @brief A random-access input wrapper for transforming dereferenced values.
6262
*
6363
* @par Overview
64-
* - TransformInputIteratorTwraps a unary conversion functor of type
64+
* - TransformInputIterator wraps a unary conversion functor of type
6565
* @p ConversionOp and a random-access input iterator of type <tt>InputIteratorT</tt>,
6666
* using the former to produce references of type @p ValueType from the latter.
6767
* - Can be used with any data type.
@@ -71,7 +71,7 @@ CUB_NAMESPACE_BEGIN
7171
* - Compatible with Thrust API v1.7 or newer.
7272
*
7373
* @par Snippet
74-
* The code snippet below illustrates the use of @p TransformInputIteratorTto
74+
* The code snippet below illustrates the use of @p TransformInputIterator to
7575
* dereference an array of integers, tripling the values and converting them to doubles.
7676
* @par
7777
* @code

0 commit comments

Comments
 (0)