Mercurial > jwe > octave
changeset 25719:fc410b574693
maint: Merge stable to default.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 01 Aug 2018 13:38:49 -0400 |
parents | ad0b4817c09d (current diff) 216321ca4cc4 (diff) |
children | feaa2169cb36 |
files | scripts/deprecated/module.mk |
diffstat | 2 files changed, 41 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/deprecated/module.mk Mon Jul 30 06:29:43 2018 +0200 +++ b/scripts/deprecated/module.mk Wed Aug 01 13:38:49 2018 -0400 @@ -8,6 +8,7 @@ %reldir%/java2mat.m \ %reldir%/paren.m \ %reldir%/semicolon.m \ + %reldir%/setstr.m \ %reldir%/tmpnam.m \ %reldir%/toascii.m
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/scripts/deprecated/setstr.m Wed Aug 01 13:38:49 2018 -0400 @@ -0,0 +1,40 @@ +## Copyright (C) 2003-2018 John W. Eaton +## +## This file is part of Octave. +## +## Octave is free software; you can redistribute it and/or modify it +## under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 3 of the License, or (at +## your option) any later version. +## +## Octave is distributed in the hope that it will be useful, but +## WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +## General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with Octave; see the file COPYING. If not, see +## <http://www.gnu.org/licenses/>. + +## -*- texinfo -*- +## @deftypefn {Function File} {} setstr (@var{s}) +## This function has been deprecated. Use char instead. +## @end deftypefn + +## Author: jwe + +## Deprecated in version 3.0 +## Matlab still has this function, so don't remove just yet. + +function retval = setstr (varargin) + + persistent warned = false; + if (! warned) + warned = true; + warning ("Octave:deprecated-function", + "setstr is obsolete and will be removed from a future version of Octave; please use char instead"); + endif + + retval = char (varargin{:}); + +endfunction