http://www.vendian.org/parrot/wiki/bin/view.cgi/Main/ ParrotDiagramsString
On 13 Jan 2004, at 22:06, Robert Eaglestone wrote:
OK, I'm looking at the Parrot String documentation, and I've got questions. It's not like the docs are a total mess, they just need some fleshing out. Yeah, that's it. So here I go.
Here's the page I'm looking at:
http://www.parrotcode.org/docs/strings.pod.html
And here are my questions. Or, rather, notes which have questions in them.
* OK, I'm game, is 'String' a new thing that's been added to C in the last ten years? I can't find it defined anywhere; my brain must have gone to mush.
* Does it help to mention that the source code for string functions is include/parrot/string.h and string.c?
* Suppose I add some example code to the doc, creating a string and fooling around with it? Perhaps using code from a string test routine (hint, hint)? I'd do something like this, maybe:
INTVAL encoding = where/what are the encoding values?
/* is this legal? */ STRING* foo = string_make( pi, "foobar", 6, encoding, 0, 0 ); /* foo is "foobar" */
/* It's a pity we don't have a shorter constructor. */
STRING* bar = string_chopn( foo, 3 ); /* bar is "foo" */
/* It's also sort-of a pity we don't have this one. */ STRING* baz = string_chop( foo ); /* baz is "fo" */
* Finally, at the bottom of the doc, I see all these undocumented functions. I think I ought to document them. Any new stuff since this page was last edited?
-Rob