Added Integer::int global function.
[kakapo:rurbans-kakapo.git] / src / Pmc / Integer.nqp
1 # Copyright (C) 2010, Austin Hastings. See accompanying LICENSE file, or 
2 # http://www.opensource.org/licenses/artistic-license-2.0.php for license.
3
4 module Integer;
5
6 INIT {
7         Global::inject_root_symbol( Integer::int );
8 }
9
10 sub int($x) {
11         Q:PIR {
12                 $P0 = find_lex '$x'
13                 $I0 = $P0
14                 .return ($I0)
15         };
16 }