Strings are much different then ADC. I can't read a NULL character,
but I can read a 0 value ADC. If we don't have a standard, people will
be forced to use both procedures at the same time due to library
usage. There's no point in duplicate or alike code. For example,
someone may want to use Minix lib + Networking lib which currently
both use a different method.

Joep, what would you prefer? Anyone else have an opinion?

Matt.

On Jun 1, 1:53 am, Sebastien Lelong <[email protected]>
wrote:
> I wouldn't agree with the above procedure. Leaving strings, it's like when
> picking a value considered as None or NULL (no result, consider a ADC
> function: either return a analog value, either no results because couldn't
> perform ADC for instance). Say, when a function returns 0 this means there's
> no result. But does this mean 0 means "no results" for any function ? Of
> cource not (analog value could actually 0).
>
> That's the same for strings: does NULL char means end of string ? Not
> necessarily, it depends on the context. And as Joep says, picking a value
> within [0,255] as termination char is moving the issue (ADC values can go
> from 0 to 255). And using escape char waste one more byte...
>
> You can't try to create generic library wheil saying "if someone insist they
> can create their own procedures" :) particularly when, currently, there's a
> way to deal with both ways. Are you actually trying to refactor both
> functions ? (that's different than mixing NULL and not NULL terminated
> chars)
>
> Oh dear, I shouldn't have opened the NULL strings pandora box :)
>
> Cheers,
> Seb
>
> 2011/6/1 mattschinkel <[email protected]>
>
> > > But being devil's advocate, I could use strings containing NULL char, but
> > > this doesn't mean end of string.
>
> > True, if someone insists, they can make their own procedures. I don't
> > think we need to worry about this. This is only for consistency in our
> > libraries. Of course, the other option is to use two characters like
> > "\x".
>
> > So, do you agree with the above procedure?
>
> > Matt.
>
> --
> Sébastien Lelong

-- 
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/jallib?hl=en.

Reply via email to