Skip to content
Newer
Older
100644 57 lines (34 sloc) 1.48 KB
5b9746a Wrote this a few days ago, but forgot to svn add.
wayland authored
1
2 =encoding utf8
3
04840a3 [Spec] treat all authors equally
lwall authored
4 =head1 TITLE
5b9746a Wrote this a few days ago, but forgot to svn add.
wayland authored
5
6 DRAFT: Synopsis 21: Calling Foreign Code
7
04840a3 [Spec] treat all authors equally
lwall authored
8 =head1 AUTHORS
5b9746a Wrote this a few days ago, but forgot to svn add.
wayland authored
9
04840a3 [Spec] treat all authors equally
lwall authored
10 Tim Nelson <wayland@wayland.id.au>
11 Larry Wall <larry@wall.org>
12 Tim Nelson <wayland@wayland.id.au>
13
14 =head1 VERSION
15
16 Created: 27 Feb 2009
17
18 Last Modified: 27 Feb 2009
19 Version: 1
5b9746a Wrote this a few days ago, but forgot to svn add.
wayland authored
20
21 The document is a draft.
22
23 If you read the HTML version, it is generated from the pod in the pugs
24 repository under /docs/Perl6/Spec/S21-calling-foreign-code.pod so edit it there in
25 the SVN repository if you would like to make changes.
26
27 =head1 Overview
28
29 Unfortunately, calling foreign code properly is quite platform dependent. This means that
30 parts of the external calling conventions can't be standardised. But the parts that can
31 be standardised are specified here.
32
33 =head1 Specification
4b993cb add some X<>-es to the docs
szabgab authored
34 X<use>
5b9746a Wrote this a few days ago, but forgot to svn add.
wayland authored
35
36 The C<use> statement allows an external language to be specified in
37 addition to (or instead of) an authority, so that you can use modules
38 from other languages. The C<from> adverb also parses any additional
39 parts as short-form arguments. For instance:
40
41 use Whiteness:from<perl5>:name<Acme::Bleach>:ver<1.12>:auth<cpan:DCONWAY>;
42 use Whiteness:from<perl5 Acme::Bleach 1.12 cpan:DCONWAY>; # same thing
43
44 use libc:from<C>;
45
46 =head1 Other Considerations
47
48 =head2 Linking to common platforms
49
50 XXX We need a discussion of how to link to some of the common platforms
51
52 =head1 Additions
53
54 Please post errors and feedback to perl6-language. If you are making
55 a general laundry list, please separate messages by topic.
56
Something went wrong with that request. Please try again.