Yes, it compiles for me, but to your point I'll clean up the declarations within the post. I've been using C++ a lot more than C lately, and given the similarities in syntax between the two it starts to get easy to let one leak into the other. I learned Portuguese as a second language, and then picked up Spanish along the way a few years later. Both being romance languages, there are enough similarities that I found it necessary to concentrate on not slipping a Portuguese-specific word into my Spanish.

Thanks for taking a look at it. This is the sort of thing that if I'm going to invest the time in learning it, I want to learn it right.

I considered picking up the Extending and Embedding Perl book, but given that it came along before 5.8.8 (I think), there have been changes to XS since then that might make the book more trouble than it's worth. If anyone reading this knows otherwise let me know and I'll probably go pick up a copy somewhere. Meanwhile, POD, tinker, and more POD.


Dave


In reply to Re^4: When to (and not to) use sv_2mortal() by davido
in thread When to (and not to) use sv_2mortal() by davido

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.