Mercurial > hg > octave-nkf
changeset 16939:06897f865f0b
Add flintmax() as an alias for function bitmax().
* NEWS: Announce new function.
* libinterp/corefcn/bitfcns.cc(Fbitmax): Adjust docstring to mention
flintmax calling form. Use DEFALIAS macro to set flintmax equal
to existing bitmax function.
* doc/interpreter/numbers.txi: Put anchor in documentation for new alias.
* scripts/help/__unimplemented__.m: Remove from unimplemented list.
author | Rik <rik@octave.org> |
---|---|
date | Tue, 09 Jul 2013 16:08:16 -0700 |
parents | 78c022f1d6f7 |
children | 99122191d3dd |
files | NEWS doc/interpreter/numbers.txi libinterp/corefcn/bitfcns.cc scripts/help/__unimplemented__.m |
diffstat | 4 files changed, 26 insertions(+), 18 deletions(-) [+] |
line wrap: on
line diff
--- a/NEWS +++ b/NEWS @@ -187,21 +187,21 @@ ** Other new functions added in 3.8.0: - atan2d erfcinv readline_re_read_init_file - base64_decode erfi readline_read_init_file - base64_encode expint rgbplot - betaincinv findfigs save_default_options - built_in_docstrings_file fminsearch shrinkfaces - cmpermute gallery splinefit - cmunique gco stemleaf - colorcube hdl2struct strjoin - copyobj history_save struct2hdl - dawson imformats tetramesh - dblist importdata waterfall - debug_jit iscolormap - doc_cache_create jit_enable - ellipj lines - ellipke polyeig + atan2d erfcinv polyeig + base64_decode erfi readline_re_read_init_file + base64_encode expint readline_read_init_file + betaincinv findfigs rgbplot + built_in_docstrings_file flintmax save_default_options + cmpermute fminsearch shrinkfaces + cmunique gallery splinefit + colorcube gco stemleaf + copyobj hdl2struct strjoin + dawson history_save struct2hdl + dblist imformats tetramesh + debug_jit importdata waterfall + doc_cache_create iscolormap + ellipj jit_enable + ellipke lines ** Deprecated functions.
--- a/doc/interpreter/numbers.txi +++ b/doc/interpreter/numbers.txi @@ -614,9 +614,10 @@ for bit manipulation, particularly when forming masks, Octave supplies the function @code{bitmax}. +@anchor{docXflintmax} @DOCSTRING(bitmax) -This is the double precision version of the functions @code{intmax}, +This is the double precision version of the function @code{intmax}, previously discussed. Octave also includes the basic bitwise 'and', 'or' and 'exclusive or'
--- a/libinterp/corefcn/bitfcns.cc +++ b/libinterp/corefcn/bitfcns.cc @@ -567,9 +567,15 @@ @deftypefn {Built-in Function} {} bitmax ()\n\ @deftypefnx {Built-in Function} {} bitmax (\"double\")\n\ @deftypefnx {Built-in Function} {} bitmax (\"single\")\n\ +@deftypefnx {Built-in Function} {} flintmax (@dots{})\n\ Return the largest integer that can be represented within a floating point\n\ value. The default class is \"double\", but \"single\" is a valid option.\n\ -On IEEE-754 compatible systems, @code{bitmax} is @w{@math{2^{53} - 1}}.\n\ +On IEEE-754 compatible systems, @code{bitmax} is @w{@math{2^{53} - 1}} for\n\ +\"double\" and @w{@math{2^{24} -1}} for \"single\".\n\ +\n\ +@code{flintmax} for FLoating point INTeger MAXimum is an alias for\n\ +@code{bitmax}.\n\ +@seealso{intmax, realmax, realmin}\n\ @end deftypefn") { octave_value retval; @@ -594,6 +600,8 @@ return retval; } +DEFALIAS(flintmax, bitmax) + DEFUN (intmax, args, , "-*- texinfo -*-\n\ @deftypefn {Built-in Function} {} intmax (@var{type})\n\