changeset 24040:8e8dbabd6e84

ov.h(fast_elem_insert): Remove "virtual" declaration. No function except `fast_elem_insert` is declared virtual in ov.h. There is no obvious reason, as no class inherits from wrapper class `octave_value`. Therefore remove that keyword to be consistent. For a discussion, see: https://lists.gnu.org/archive/html/octave-maintainers/2017-08/msg00149.html Improve some comments for Doxygen in that file.
author Kai T. Ohlhus <k.ohlhus@gmail.com>
date Thu, 14 Sep 2017 14:07:33 +0200
parents 530d5e9202ee
children 1d5c85655a8f
files libinterp/octave-value/ov.h
diffstat 1 files changed, 19 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/octave-value/ov.h	Thu Sep 14 13:22:44 2017 +0200
+++ b/libinterp/octave-value/ov.h	Thu Sep 14 14:07:33 2017 +0200
@@ -1461,18 +1461,28 @@
   octave_value map (octave_base_value::unary_mapper_t umap) const
   { return rep->map (umap); }
 
-  // Extract the n-th element, aka val(n).
-  // Result is undefined if val is not an array type or n is out of range.
-  // Never error.
+  /*!
+   * \brief Extract the n-th element, aka `val(n)`.
+   *
+   * \return Result is undefined if `val` is not an array type
+   *                                or \p n is out of range.
+   *
+   * \warning Function calls should never error.
+   */
   octave_value
   fast_elem_extract (octave_idx_type n) const
   { return rep->fast_elem_extract (n); }
 
-  // Assign the n-th element, aka val(n) = x.
-  // Return false if val is not an array type, x is not a matching scalar type,
-  // or n is out of range.
-  // Never error.
-  virtual bool
+  /*!
+   * \brief Assign the n-th element, aka `val(n) = x`.
+   *
+   * \returns false if `val` is not an array type,
+   *                   \p x is not a matching scalar type,
+   *                   or \p n is out of range.
+   *
+   * \warning Function calls should never error.
+   */
+  bool
   fast_elem_insert (octave_idx_type n, const octave_value& x)
   {
     make_unique ();
@@ -1481,7 +1491,7 @@
 
 protected:
 
-  // The real representation.
+  //! The real representation.
   octave_base_value *rep;
 
 private: