
Robert Acock
- Website: lnation.org
Recent Actions
-
Commented on Learning XS - Closures
Is this the correct way to free the HV? ``` void euthanase(kitty) CV * kitty CODE: SvREFCNT_dec(CvXSUBANY(kitty).any_ptr); ```...
-
Commented on Learning XS - Closures
I have only been learning C/XS for a short period of time, I have touched typemaps but would need to 'experiment' with them more before I could write a post. My current understanding to what they allow you todo is...
-
Posted Learning XS - Closures to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This tenth post introduces you to what I call closures in XS.
-
Posted Learning XS - C data types to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This ninth post introduces you to C data types and how to expose them in…
-
Posted Learning XS - Regular Expressions to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This eighth post introduces you to Perl regular expressions in…
-
Posted Learning XS - Exporting to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This seventh post introduces you to exporting XSUBS.
-
Posted Learning XS - Invocation to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This sixth post introduces you to subroutine invocation in…
-
Posted Learning XS - Prototyping to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This fifth post introduces you to subroutine(method/function) prototypes in…
-
Posted Learning XS - Overloading to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This fourth post introduces you to overloading operators in…
-
Posted Learning XS - List context to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This third post introduces you to list context in XS.
-
Posted Learning XS - What is in my variable to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This second post introduces the fundamentals of type checking variables in…
-
Posted Learning XS - How to create an object to Robert Acock
Over the past year, I’ve been self-studying XS and have now decided to share my learning journey through a series of blog posts. This first post introduces the fundamentals of creating an perl object from XS.
-
Commented on Faster Readonly variables with Const::XS
My benchmark measures both instantiation and access. If I were to benchmark only access, Const::Fast and Const::XS would show very similar performance. I include both in the benchmark because it's relevant in scripting scenarios, where the process isn't long-running, and...
-
Commented on Faster Readonly variables with Const::XS
Thanks updated the link and no such limitations with Const::XS they are just 'variables' so concatenating like "$STRING $HASH{ONE} $ARRAY[0]" is fine....
-
Posted Faster Readonly variables with Const::XS to Robert Acock
So, what exactly is a Readonly variable in Perl? A readonly variable is one that, once assigned a value, cannot be changed. Any attempt to modify it will trigger a runtime error. This mechanism enforces immutability, ensuring that critical values remain untouched and are protected from accidental…
-
Commented on I want to display NA instead of UNKKONW in CPAN Testers
Then decides to look at your link - Argument "8.0_beta" isn't numeric in numeric lt (...
-
Commented on I want to display NA instead of UNKKONW in CPAN Testers
Die inside your Makefile, doesn't have to be in a BEGIN block. For example if I wanted a module only to work for macOS then: die "OS unsupported" unless $^O eq 'darwin';...
-
Commented on C::Blocks Advent Day 1
David Mertens++....
-
Commented on I create "Perl Tweet Timeline News" Web site
Takes back previous comment, improvements....
-
Commented on I create "Perl Tweet Timeline News" Web site
Just a thought, because I don't think the content returned via twitter is actually that useful. What you could do... is search for the links and generate some content from them title, description ect. Majority of modern web sites(blogs) support...
-
Commented on Social Media Meta Tags
I should add thank you to those that have emailed me some feedback, It's appreciated and I'll take it forward in my next release....
-
Commented on Social Media Meta Tags
Hey Ron, I submitted a post to prepan back on the 12/12/2015 you can find it here... http://prepan.org/module/nY8EjAnEF8c like many other posts on prepan it has no comments and no feedback. I apologise for my lack of proof reading....
-
Commented on Social Media Meta Tags
Hey Dudes, I know you're all really busy and probably care very little about this module. But I'm a junior developer who really wants to learn and improve. What I was hoping from this post was at least some critical...
-
Posted Social Media Meta Tags to Robert Acock
Social Media Meta Tags
Social media meta tags are HTML tags that allow you to make the most out of the content you share from a URL. You can determine what information is displayed from a post in Twitter, Facebook, LinkedIn, Pinterest and beyond. It gives developers control over the expe…

Comment Threads
-
Yuki Kimoto commented on
I want to display NA instead of UNKKONW in CPAN Testers
My case is that support only 64bit interger Perl and NetBSD 7+.
# SPVM only support 64bit integer Perl
my $ivsize = $Config{ivsize};
if ($ivsize die "SPVM don't support the Perl which \"ivsize\" is lower than 8";
}# SPVM only support NetBSD 7+
if ($Config{osname} eq 'netbsd' && $Config{osvers} die "SPVM don't support NetBSD 6, 5, 4, 3, 2, 1";
}In this case, I get NA
-
lowjoe commented on
Faster Readonly variables with Const::XS
You should focus the benchmarks only on usage, not on creation. No user who cares about performance is defining constants in a tight loop.
And don't forget about neilb's excellent roundup of constant modules: https://neilb.org/reviews/constants.html
-
Tom Wyant commented on
Faster Readonly variables with Const::XS
Note that Readonly appears to make use of Readonly::XS if that is available.
Readonly::XS
does not declare a Perl version dependency that I can see, but it is installed on my Perl 5.8.9. -
Sebastian Schleussner commented on
Faster Readonly variables with Const::XS
Line 38ff:
"Const::XS::PP::const" should be "Const::PP::const". -
Tony Cook commented on
Learning XS - Closures
That should work, you might want to set any_ptr to NULL.
An option to automatically manage the lifetime of your
self
object would be to store it in MAGIC. See https://metacpan.org/release/PEVANS/Future-XS-0.13/source/hax/cv_set_anysv_refcounted.c.inc for an example for code that uses CvREFCOUNTED_ANYSV_on() when available and magic when it isn't (thanks toddr who brought this up in IRC)

About blogs.perl.org
blogs.perl.org is a common blogging platform for the Perl community. Written in Perl with a graphic design donated by Six Apart, Ltd.