Re: [osg-users] ArgumentParser::isString bug?

2011-01-06 Thread Robert Osfield
Hi John,

There is clearly a curious change to the original isString method, and
looking at the ArgumentParser.cpp I can't spot a reason why it does
simply return true on a non NULL string, rather than return
!isOptions(str) as one might expect.

As it stands the implementation actually makes the documentation
incorrect, and it also makes the method itself of rather dubious
value.  So I'd be inclined to revert the change back to how it was, or
remove the method entirely to avoid confusion.

Robert.

On Mon, Dec 27, 2010 at 1:20 PM, John Kelso  wrote:
> Hi,
>
> I've decided to give the osg ArgumentParser class a try.
>
> Is the method:
>
> bool ArgumentParser::isString(const char* str)
> {
>    if (!str) return false;
>    return true;
>    //return !isOption(str);
> }
>
> doing as advertised?  The comment says:
>    /** Return true if string is non-NULL and not an option in the form
>      * -option or --option. */
>
> Thanks,
>
> John
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] ArgumentParser::isString bug?

2010-12-27 Thread John Kelso

Hi,

I've decided to give the osg ArgumentParser class a try.

Is the method:

bool ArgumentParser::isString(const char* str)
{
if (!str) return false;
return true;
//return !isOption(str);
}

doing as advertised?  The comment says:
/** Return true if string is non-NULL and not an option in the form
  * -option or --option. */

Thanks,

John
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org