Skip to content

Commit 86e8c94

Browse files
committed
[ntuple][NFC] Add/remove backticks where appropriate
1 parent 91c3ff6 commit 86e8c94

File tree

4 files changed

+36
-36
lines changed

4 files changed

+36
-36
lines changed

tree/ntuple/inc/ROOT/RField/RFieldFundamental.hxx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -431,15 +431,15 @@ public:
431431

432432
/// Sets this field to use a half precision representation, occupying half as much storage space (16 bits:
433433
/// 1 sign bit, 5 exponent bits, 10 mantissa bits) on disk.
434-
/// This is mutually exclusive with `SetTruncated` and `SetQuantized` and supersedes them if called after them.
434+
/// This is mutually exclusive with SetTruncated() and SetQuantized() and supersedes them if called after them.
435435
void SetHalfPrecision() { SetColumnRepresentatives({{ROOT::ENTupleColumnType::kReal16}}); }
436436

437437
/// Set the on-disk representation of this field to a single-precision float truncated to `nBits`.
438438
/// The remaining (32 - `nBits`) bits will be truncated from the number's mantissa.
439439
/// `nBits` must be $10 <= nBits <= 31$ (this means that at least 1 bit
440440
/// of mantissa is always preserved). Note that this effectively rounds the number towards 0.
441441
/// For a double-precision field, this implies first a cast to single-precision, then the truncation.
442-
/// This is mutually exclusive with `SetHalfPrecision` and `SetQuantized` and supersedes them if called after them.
442+
/// This is mutually exclusive with SetHalfPrecision() and SetQuantized() and supersedes them if called after them.
443443
void SetTruncated(std::size_t nBits)
444444
{
445445
const auto &[minBits, maxBits] =
@@ -455,12 +455,12 @@ public:
455455

456456
/// Sets this field to use a quantized integer representation using `nBits` per value.
457457
/// It must be $1 <= nBits <= 32$.
458-
/// `minValue` and `maxValue` must not be infinity, NaN or denormal floats, and they must be representable by the
459-
/// type T.
458+
/// `minValue` and `maxValue` must not be infinity, `NaN` or denormal floats, and they must be representable by the
459+
/// type `T`.
460460
/// Calling this function establishes a promise by the caller to RNTuple that this field will only contain values
461461
/// contained in `[minValue, maxValue]` inclusive. If a value outside this range is assigned to this field, the
462462
/// behavior is undefined.
463-
/// This is mutually exclusive with `SetTruncated` and `SetHalfPrecision` and supersedes them if called after them.
463+
/// This is mutually exclusive with SetTruncated() and SetHalfPrecision() and supersedes them if called after them.
464464
void SetQuantized(double minValue, double maxValue, std::size_t nBits)
465465
{
466466
const auto &[minBits, maxBits] =
@@ -514,7 +514,7 @@ public:
514514

515515
void AcceptVisitor(ROOT::Detail::RFieldVisitor &visitor) const final;
516516

517-
// Set the column representation to 32 bit floating point and the type alias to Double32_t
517+
// Set the column representation to 32 bit floating point and the type alias to `Double32_t`
518518
void SetDouble32();
519519
};
520520

tree/ntuple/inc/ROOT/RField/RFieldProxiedCollection.hxx

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -39,19 +39,19 @@ namespace Detail {
3939
class RFieldVisitor;
4040
} // namespace Detail
4141

42-
/// The field for a class representing a collection of elements via `TVirtualCollectionProxy`.
42+
/// The field for a class representing a collection of elements via TVirtualCollectionProxy.
4343
/// Objects of such type behave as collections that can be accessed through the corresponding member functions in
44-
/// `TVirtualCollectionProxy`. For STL collections, these proxies are provided. Custom classes need to implement the
45-
/// corresponding member functions in `TVirtualCollectionProxy`. At a bare minimum, the user is required to provide an
46-
/// implementation for the following functions in `TVirtualCollectionProxy`: `HasPointers()`, `GetProperties()`,
47-
/// `GetValueClass()`, `GetType()`, `PushProxy()`, `PopProxy()`, `GetFunctionCreateIterators()`, `GetFunctionNext()`,
48-
/// and `GetFunctionDeleteTwoIterators()`.
44+
/// TVirtualCollectionProxy. For STL collections, these proxies are provided. Custom classes need to implement the
45+
/// corresponding member functions in TVirtualCollectionProxy. At a bare minimum, the user is required to provide an
46+
/// implementation for the following functions in TVirtualCollectionProxy: HasPointers(), GetProperties(),
47+
/// GetValueClass(), GetType(), PushProxy(), PopProxy(), GetFunctionCreateIterators(), GetFunctionNext(),
48+
/// and GetFunctionDeleteTwoIterators().
4949
///
50-
/// The collection proxy for a given class can be set via `TClass::CopyCollectionProxy()`.
50+
/// The collection proxy for a given class can be set via TClass::CopyCollectionProxy().
5151
class RProxiedCollectionField : public RFieldBase {
5252
protected:
5353
/// Allows for iterating over the elements of a proxied collection. RCollectionIterableOnce avoids an additional
54-
/// iterator copy (see `TVirtualCollectionProxy::GetFunctionCopyIterator`) and thus can only be iterated once.
54+
/// iterator copy (see TVirtualCollectionProxy::GetFunctionCopyIterator) and thus can only be iterated once.
5555
class RCollectionIterableOnce {
5656
public:
5757
struct RIteratorFuncs {
@@ -70,7 +70,7 @@ protected:
7070
void Advance()
7171
{
7272
auto fnNext_Contig = [&]() {
73-
// Array-backed collections (e.g. kSTLvector) directly use the pointer-to-iterator-data as a
73+
// Array-backed collections (e.g. `kSTLvector`) directly use the pointer-to-iterator-data as a
7474
// pointer-to-element, thus saving an indirection level (see documentation for TVirtualCollectionProxy)
7575
auto &iter = reinterpret_cast<unsigned char *&>(fIterator), p = iter;
7676
iter += fOwner.fStride;
@@ -105,7 +105,7 @@ protected:
105105
void *fEnd = &fEndSmallBuf;
106106

107107
public:
108-
/// Construct a `RCollectionIterableOnce` that iterates over `collection`. If elements are guaranteed to be
108+
/// Construct a RCollectionIterableOnce that iterates over `collection`. If elements are guaranteed to be
109109
/// contiguous in memory (e.g. a vector), `stride` can be provided for faster iteration, i.e. the address of each
110110
/// element is known given the base pointer.
111111
RCollectionIterableOnce(void *collection, const RIteratorFuncs &ifuncs, TVirtualCollectionProxy *proxy,
@@ -152,7 +152,7 @@ protected:
152152
/// Constructor used when the value type of the collection is not known in advance, i.e. in the case of custom
153153
/// collections.
154154
RProxiedCollectionField(std::string_view fieldName, TClass *classp);
155-
/// Constructor used when the value type of the collection is known in advance, e.g. in `RSetField`.
155+
/// Constructor used when the value type of the collection is known in advance, e.g. in RSetField.
156156
RProxiedCollectionField(std::string_view fieldName, std::string_view typeName,
157157
std::unique_ptr<RFieldBase> itemField);
158158

@@ -208,7 +208,7 @@ struct HasCollectionProxyMemberType<
208208
/// The point here is that we can only tell at run time if a class has an associated collection proxy.
209209
/// For compile time, in the first iteration of this PR we had an extra template argument that acted as a "tag" to
210210
/// differentiate the RField specialization for classes with an associated collection proxy (inherits
211-
/// `RProxiedCollectionField`) from the RField primary template definition (`RClassField`-derived), as in:
211+
/// RProxiedCollectionField) from the RField primary template definition (RClassField-derived), as in:
212212
/// ```
213213
/// auto field = std::make_unique<RField<MyClass>>("klass");
214214
/// // vs
@@ -223,7 +223,7 @@ struct HasCollectionProxyMemberType<
223223
/// ```
224224
/// auto field = std::make_unique<RField<RProxiedCollection<MyClass>>>("klass"); // Using collection proxy
225225
/// ```
226-
/// - A helper `IsCollectionProxy<T>` type, that can be used in a similar way to those in the `<type_traits>` header.
226+
/// - A helper IsCollectionProxy<T> type, that can be used in a similar way to those in the `<type_traits>` header.
227227
/// We found this more convenient and is the implemented thing below. Here, classes can be marked as a
228228
/// collection proxy with either of the following two forms (whichever is more convenient for the user):
229229
/// ```
@@ -238,15 +238,15 @@ struct HasCollectionProxyMemberType<
238238
/// };
239239
/// ```
240240
///
241-
/// Of course, there is another possible solution which is to have a single `RClassField` that implements both
241+
/// Of course, there is another possible solution which is to have a single RClassField that implements both
242242
/// the regular-class and the collection-proxy behaviors, and always chooses appropriately at run time.
243243
/// We found that less clean and probably has more overhead, as most probably it involves an additional branch + call
244244
/// in each of the member functions.
245245
template <typename T, typename = void>
246246
struct IsCollectionProxy : HasCollectionProxyMemberType<T> {
247247
};
248248

249-
/// Classes behaving as a collection of elements that can be queried via the `TVirtualCollectionProxy` interface
249+
/// Classes behaving as a collection of elements that can be queried via the TVirtualCollectionProxy interface
250250
/// The use of a collection proxy for a particular class can be enabled via:
251251
/// ```
252252
/// namespace ROOT::Experimental {
@@ -277,7 +277,7 @@ public:
277277
/// Template specializations for C++ std::[unordered_][multi]map
278278
////////////////////////////////////////////////////////////////////////////////
279279

280-
/// The generic field for a std::map<KeyType, ValueType> and std::unordered_map<KeyType, ValueType>
280+
/// The generic field for a `std::map<KeyType, ValueType>` and `std::unordered_map<KeyType, ValueType>`
281281
class RMapField : public RProxiedCollectionField {
282282
public:
283283
RMapField(std::string_view fieldName, std::string_view typeName, std::unique_ptr<RFieldBase> itemField);
@@ -358,7 +358,7 @@ public:
358358
/// Template specializations for C++ std::[unordered_][multi]set
359359
////////////////////////////////////////////////////////////////////////////////
360360

361-
/// The generic field for a std::set<Type> and std::unordered_set<Type>
361+
/// The generic field for a `std::set<Type>` and `std::unordered_set<Type>`
362362
class RSetField : public RProxiedCollectionField {
363363
public:
364364
RSetField(std::string_view fieldName, std::string_view typeName, std::unique_ptr<RFieldBase> itemField);

tree/ntuple/inc/ROOT/RField/RFieldSTLMisc.hxx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public:
8282
/// Template specializations for C++ std::bitset
8383
////////////////////////////////////////////////////////////////////////////////
8484

85-
/// The generic field an std::bitset<N>. All compilers we care about store the bits in an array of unsigned long.
85+
/// The generic field an `std::bitset<N>`. All compilers we care about store the bits in an array of unsigned long.
8686
/// TODO(jblomer): reading and writing efficiency should be improved; currently it is one bit at a time
8787
/// with an array of bools on the page level.
8888
class RBitsetField : public RFieldBase {
@@ -116,7 +116,7 @@ public:
116116
size_t GetAlignment() const final { return alignof(Word_t); }
117117
void AcceptVisitor(ROOT::Detail::RFieldVisitor &visitor) const final;
118118

119-
/// Get the number of bits in the bitset, i.e. the N in std::bitset<N>
119+
/// Get the number of bits in the bitset, i.e. the `N` in `std::bitset<N>`
120120
std::size_t GetN() const { return fN; }
121121
};
122122

@@ -163,7 +163,7 @@ public:
163163
/// The field for values that may or may not be present in an entry. Parent class for unique pointer field and
164164
/// optional field. A nullable field cannot be instantiated itself but only its descendants.
165165
/// The RNullableField takes care of the on-disk representation. Child classes are responsible for the in-memory
166-
/// representation. Nullable fields use a (Split)Index[64|32] column to point to the available items.
166+
/// representation. Nullable fields use a `(Split)Index[64|32]` column to point to the available items.
167167
class RNullableField : public RFieldBase {
168168
/// The number of written non-null items in this cluster
169169
ROOT::Internal::RColumnIndex fNWritten{0};
@@ -178,7 +178,7 @@ protected:
178178
void CommitClusterImpl() final { fNWritten = 0; }
179179

180180
/// Given the index of the nullable field, returns the corresponding global index of the subfield or,
181-
/// if it is null, returns kInvalidNTupleIndex
181+
/// if it is null, returns `kInvalidNTupleIndex`
182182
RNTupleLocalIndex GetItemIndex(ROOT::NTupleSize_t globalIndex);
183183

184184
RNullableField(std::string_view fieldName, std::string_view typeName, std::unique_ptr<RFieldBase> itemField);
@@ -205,8 +205,8 @@ class ROptionalField : public RNullableField {
205205

206206
std::unique_ptr<RDeleter> fItemDeleter;
207207

208-
/// Given a pointer to an std::optional<T> in `optionalPtr`, extract a pointer to the engagement boolean.
209-
/// Assumes that an std::optional<T> is stored as `struct { T t; bool engagement; };`
208+
/// Given a pointer to an `std::optional<T>` in `optionalPtr`, extract a pointer to the engagement boolean.
209+
/// Assumes that an `std::optional<T>` is stored as `struct { T t; bool engagement; };`
210210
const bool *GetEngagementPtr(const void *optionalPtr) const;
211211
bool *GetEngagementPtr(void *optionalPtr) const;
212212
std::size_t GetEngagementPtrOffset() const;
@@ -354,14 +354,14 @@ private:
354354

355355
size_t fMaxItemSize = 0;
356356
size_t fMaxAlignment = 1;
357-
/// In the std::variant memory layout, at which byte number is the index stored
357+
/// In the `std::variant` memory layout, at which byte number is the index stored
358358
size_t fTagOffset = 0;
359-
/// In the std::variant memory layout, the actual union of types may start at an offset > 0
359+
/// In the `std::variant` memory layout, the actual union of types may start at an offset > 0
360360
size_t fVariantOffset = 0;
361361
std::vector<ROOT::Internal::RColumnIndex::ValueType> fNWritten;
362362

363363
static std::string GetTypeList(const std::vector<std::unique_ptr<RFieldBase>> &itemFields);
364-
/// Extracts the index from an std::variant and transforms it into the 1-based index used for the switch column
364+
/// Extracts the index from an `std::variant` and transforms it into the 1-based index used for the switch column
365365
/// The implementation supports two memory layouts that are in use: a trailing unsigned byte, zero-indexed,
366366
/// having the exception caused empty state encoded by the max tag value,
367367
/// or a trailing unsigned int instead of a char.

tree/ntuple/inc/ROOT/RField/RFieldSequenceContainer.hxx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ public:
186186
/// Template specializations for C++ std::vector
187187
////////////////////////////////////////////////////////////////////////////////
188188

189-
/// The generic field for a (nested) std::vector<Type> except for std::vector<bool>
189+
/// The generic field for a (nested) `std::vector<Type>` except for `std::vector<bool>`
190190
/// The field can be constructed as untyped collection through CreateUntyped().
191191
class RVectorField : public RFieldBase {
192192
private:
@@ -260,7 +260,7 @@ public:
260260
~RField() final = default;
261261
};
262262

263-
// std::vector<bool> is a template specialization and needs special treatment
263+
// `std::vector<bool>` is a template specialization and needs special treatment
264264
template <>
265265
class RField<std::vector<bool>> final : public RFieldBase {
266266
private:
@@ -317,7 +317,7 @@ public:
317317
\brief A field for fixed-size arrays that are represented as RVecs in memory.
318318
\ingroup NTuple
319319
This class is used only for reading. In particular, it helps exposing
320-
arbitrarily-nested std::array on-disk fields as RVecs for usage in RDataFrame.
320+
arbitrarily-nested `std::array` on-disk fields as RVecs for usage in RDataFrame.
321321
*/
322322
class RArrayAsRVecField final : public RFieldBase {
323323
private:
@@ -341,7 +341,7 @@ protected:
341341

342342
public:
343343
/**
344-
Constructor of the field. The itemField argument represents the inner
344+
Constructor of the field. The `itemField` argument represents the inner
345345
item of the on-disk array, i.e. for an `std::array<float>` it is the `float`
346346
field and not the `std::array` itself.
347347
*/

0 commit comments

Comments
 (0)