Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
But Perl 6 has the Native Calling Interface which allows you to "Call into dynamic libraries that follow the C calling convention". This means that if you're using XS for accessing external libraries, you won't have to use XS. Which I think a lot of people would see as a plus. For example, this is the code to interface with the C-function ctime:
use NativeCall; sub the-time(Int() $it = time) { # coerce to Int, cu +rrent time default sub ctime(int64 is rw --> Str) is native {*}; # the actual interf +ace my int $time = $it; # the rest is synta +ctic sugar, really. ctime($time) }; # the actual call i +nto the C-library } say the-time; # Sun Jul 15 17:05:34 2018
And if you want to interface with your own C-code: turn it into a small library and call that using NativeCall. The t/04-nativecall directory contains several examples of how to do this. All in all, I'd say not having XS is a plus, rather than a minus. As it is XS out there in the wild, that is keeping Perl 5 from advancing in the multi-threaded world. Which is also why Perl 5 ithreads continue to have scalability issues for the past 15 years!

In reply to Re^5: It has been suggested to rename Perl 6 in order to boost its marketing potential. Which name would you prefer? by liz
in thread It has been suggested to rename Perl 6 in order to boost its marketing potential. Which name would you prefer? by martin

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (3)
As of 2022-09-25 16:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I prefer my indexes to start at:




    Results (116 votes). Check out past polls.

    Notices?