view test/bug-59661/bug59661.m @ 30239:120e878f343f

mkdir.m: issue a warning if DIR already exists (bug #61338) * mkdir.m: When nargout==0, check status message and report a warning if "directory exists" message found.
author Rik <rik@octave.org>
date Wed, 13 Oct 2021 08:05:14 -0700
parents 370b5ded5e6a
children
line wrap: on
line source

classdef bug59661 < handle

  properties
    p = [];
  endproperties

  methods

    function o = bug59661 (varargin)
      o.p = [varargin{:}];
    endfunction

    function res = eq (a, b)

      if (numel (a.p) > 1 && numel (b.p) > 1 && ! isequal (size (a.p), size (b.p)))
        res = false;
        return;
      endif

      if (isequal (size (a.p), size (b.p)))
        res = eq (a.p, b.p);
      else
        res = bsxfun (@eq, a.p, b.p);
      endif

    endfunction

  endmethods
endclassdef