octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error with pkg.m (== isspace does work with cell arrays anymore)


From: Daniel J Sebald
Subject: Re: Error with pkg.m (== isspace does work with cell arrays anymore)
Date: Mon, 25 Feb 2008 15:39:51 -0600
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20041020

John W. Eaton wrote:
On 24-Feb-2008, Michael Goffioul wrote:

| I have an error with recent mercurial code, in pkg.m. It reduces to
| the fact that isspace does not work anymore on cell array of
| strings. The error occurs around line 1299:
| | if (! all (isspace (filenames))) | | where filenames is a cell array of strings. I'm not sure what's
| the correct way to fix this.

I could probably help if I knew what isspace should do for a cell
array.  Matlab appears to do this:

>> isspace ({' ', ' ', ' '})
  ans =

       0     0     0


Which makes no sense to me.  Is this behavior useful in some way that
I'm not seeing?

Well, in that case the question is whether the cell is a space, which I suppose 
it isn't.  Consider:

octave:14> ['left' ' ' 'right']
ans = left right
octave:15> ['left' {' '} 'right']
error: concatenation operator not implemented for `sq_string' by `cell' 
operations
octave:15> ['left' {' '}{} 'right']
ans = left right

Dan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]