Skip to content

Commit

Permalink
Fix fixed_point binary operation documentation (#10198)
Browse files Browse the repository at this point in the history
As pointed out by @bdice in #10179, the docs are backwards for some of the binary operations on `fixed_point`. This PR fixes them and removes the `<br>` HTML tag as well.

Authors:
  - Conor Hoekstra (https://github.com/codereport)

Approvers:
  - Bradley Dice (https://github.com/bdice)
  - David Wendt (https://github.com/davidwendt)
  - MithunR (https://github.com/mythrocks)

URL: #10198
  • Loading branch information
codereport authored Feb 3, 2022
1 parent b7257a3 commit 7d88a87
Showing 1 changed file with 27 additions and 27 deletions.
54 changes: 27 additions & 27 deletions cpp/include/cudf/fixed_point/fixed_point.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -387,9 +387,9 @@ class fixed_point {
/**
* @brief operator + (for adding two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are added <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are added
* If `_scale`s are equal, `_value`s are added.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are added.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -402,9 +402,9 @@ class fixed_point {
/**
* @brief operator - (for subtracting two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are subtracted <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are subtracted
* If `_scale`s are equal, `_value`s are subtracted.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are subtracted.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -417,7 +417,7 @@ class fixed_point {
/**
* @brief operator * (for multiplying two `fixed_point` numbers)
*
* `_scale`s are added and `_value`s are multiplied
* `_scale`s are added and `_value`s are multiplied.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -430,7 +430,7 @@ class fixed_point {
/**
* @brief operator / (for dividing two `fixed_point` numbers)
*
* `_scale`s are subtracted and `_value`s are divided
* `_scale`s are subtracted and `_value`s are divided.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -443,9 +443,9 @@ class fixed_point {
/**
* @brief operator == (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -458,9 +458,9 @@ class fixed_point {
/**
* @brief operator != (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -473,9 +473,9 @@ class fixed_point {
/**
* @brief operator <= (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -488,9 +488,9 @@ class fixed_point {
/**
* @brief operator >= (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -503,9 +503,9 @@ class fixed_point {
/**
* @brief operator < (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -518,9 +518,9 @@ class fixed_point {
/**
* @brief operator > (for comparing two `fixed_point` numbers)
*
* If `_scale`s are equal, `_value`s are compared <br>
* If `_scale`s are not equal, number with smaller `_scale` is shifted to the
* greater `_scale`, and then `_value`s are compared
* If `_scale`s are equal, `_value`s are compared.
* If `_scale`s are not equal, the number with the larger `_scale` is shifted to the
* smaller `_scale`, and then the `_value`s are compared.
*
* @tparam Rep1 Representation type of number being added to `this`
* @tparam Rad1 Radix (base) type of number being added to `this`
Expand All @@ -534,7 +534,7 @@ class fixed_point {
* @brief Method for creating a `fixed_point` number with a new `scale`
*
* The `fixed_point` number returned will have the same value, underlying representation and
* radix as `this`, the only thing changed is the scale
* radix as `this`, the only thing changed is the scale.
*
* @param scale The `scale` of the returned `fixed_point` number
* @return `fixed_point` number with a new `scale`
Expand Down

0 comments on commit 7d88a87

Please sign in to comment.