Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Add test for GH #40
This points out an issue where keyword arguments aren't being passed to Perl 5
- Loading branch information
Showing
2 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| use v6; | ||
|
|
||
| use Test; | ||
|
|
||
| use Inline::Perl5; | ||
|
|
||
| use lib:from<Perl5> <t/lib>; | ||
| use TakesHash:from<Perl5>; | ||
|
|
||
| is(TakesHash.give_hash(:foo<bar>), 'bar'); | ||
|
|
||
| done; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| package TakesHash; | ||
|
|
||
| use strict; | ||
| use warnings; | ||
|
|
||
| sub give_hash { | ||
| my ($class, %args) = @_; | ||
|
|
||
| return $args{foo}; | ||
| } | ||
|
|
||
| 1; |