Mercurial > octave
view scripts/audio/@audiorecorder/subsref.m @ 21385:89fa0694aa2e
Fix check-missing-semicolon QA target (bug #47277).
* scripts/module.mk: Recode check-missing-semicolon target to exclude
files with classdef or nested functions.
* subsref.m, subsref.m, cplxpair.m, waitbar.m, cubehelix.m, imshow.m, edit.m,
unpack.m, annotation.m, axis.m, legend.m, __contour__.m,
__ezplot__.m, __plt__.m, __gnuplot_drawnow__.m, copyobj.m, linkprop.m,
__add_default_menu__.m, __gnuplot_print__.m, __print_parse_opts__.m,
struct2hdl.m, ellipke.m, gallery.m, strjoin.m:
Add missing semicolons to statements.
author | Rik <rik@octave.org> |
---|---|
date | Thu, 25 Feb 2016 10:37:59 -0800 |
parents | 516bb87ea72e |
children | bac0d6f07a3e |
line wrap: on
line source
## Copyright (C) 2013-2015 Vytautas JanĨauskas ## ## 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 {} {@var{value} =} subsref (@var{recorder}, @var{idx}) ## Perform subscripted selection on the audio recorder object @var{recorder}. ## ## Return the recorder property value named by @var{idx}. ## @end deftypefn function value = subsref (recorder, idx) if (nargin != 2) print_usage (); endif if (isempty (idx)) error ("@audiorecorder/subsref: missing index"); endif if (strcmp (idx(1).type, ".")) field = idx.subs; value = get (recorder, field); else error ("@audiorecorder/subsref: invalid subscript type"); endif endfunction