xsawyerx/xs-fun

`PADTMP` doesn't appear in `sv_dump()` output in Chapter 04

Closed this issue · 5 comments

In Chapter 04, it is mentioned that sv_dump(value) shows that value has PADTMP in its FLAGS output. This doesn't turn up on (perlbrew-ed) perl-5.16.3, perl-5.18.2, perl-5.20.0 or perl-5.21.2 running on Debian Linux "Jessie" x86_64. Which version of perl was used to generate the output from this example? Or, another way of putting this: what did I do wrong?

I was using perl 5.14.2, as I've included in the README. Since then my machine was upgraded to 5.18.2.

Do we need to revisit this?

Sorry, I missed the note in the README. My bad.

In order to avoid confusion for people who are hopefully using 5.16+, maybe update the output for (say) 5.18? It confused me enough to open an issue about it. I can update the text with output for 5.18 and submit a PR if you want. If you don't consider this to be a huge problem, then the issue can simply be closed.

The problem is that some might have 5.14, some 5.16, and some 5.18. Oh, and 5.20, and very soon 5.22. We can't bind to a specific version. The idea is to have a minimum version of 5.14 so the XS code would be more reasonable.

We could make a note in the output saying that it might be different, depending on your Perl version.

+1 to making a note in the output. Added PR #21.

Merged. Thanks! 👍