1. my class Cool { # declared in BOOTSTRAP
  2. # class Cool is Any
  3. ## numeric methods
  4. method abs() { self.Numeric.abs }
  5. method conj() { self.Numeric.conj }
  6. method sqrt() { self.Numeric.sqrt }
  7. method sign() { self.Real.sign }
  8. method rand() { self.Num.rand }
  9. method sin() { self.Numeric.sin }
  10. method asin() { self.Numeric.asin }
  11. method cos() { self.Numeric.cos }
  12. method acos() { self.Numeric.acos }
  13. method tan() { self.Numeric.tan }
  14. method atan() { self.Numeric.atan }
  15. method atan2($y = 1e0) { self.Numeric.atan2($y.Numeric) }
  16. method sec() { self.Numeric.sec }
  17. method asec() { self.Numeric.asec }
  18. method cosec() { self.Numeric.cosec }
  19. method acosec() { self.Numeric.acosec }
  20. method cotan() { self.Numeric.cotan }
  21. method acotan() { self.Numeric.acotan }
  22. method sinh() { self.Numeric.sinh }
  23. method asinh() { self.Numeric.asinh }
  24. method cosh() { self.Numeric.cosh }
  25. method acosh() { self.Numeric.acosh }
  26. method tanh() { self.Numeric.tanh }
  27. method atanh() { self.Numeric.atanh }
  28. method sech() { self.Numeric.sech }
  29. method asech() { self.Numeric.asech }
  30. method cosech() { self.Numeric.cosech }
  31. method acosech() { self.Numeric.acosech }
  32. method cotanh() { self.Numeric.cotanh }
  33. method acotanh() { self.Numeric.acotanh }
  34. method cis() { self.Numeric.cis }
  35. proto method log(|) {*}
  36. multi method log(Cool:D: ) { self.Numeric.log }
  37. multi method log(Cool:D: $base) { self.Numeric.log($base.Numeric) }
  38. proto method exp(|) {*}
  39. multi method exp(Cool:D: ) { self.Numeric.exp }
  40. multi method exp(Cool:D: $base) { self.Numeric.exp($base.Numeric) }
  41. proto method round(|) { * }
  42. multi method round() { self.Numeric.round() }
  43. multi method round($base) { self.Numeric.round($base) }
  44. method roots(Cool $n) { self.Numeric.roots($n) }
  45. method log10() { self.Numeric.log10 }
  46. method unpolar($n) { self.Numeric.unpolar($n.Numeric) }
  47. method floor() { self.Numeric.floor }
  48. method ceiling() { self.Numeric.ceiling }
  49. method truncate() { self.Numeric.truncate }
  50. ## string methods
  51. method chars(--> Int:D) {
  52. self.Str.chars
  53. }
  54. method codes() {
  55. self.Str.codes
  56. }
  57. method fmt($format = '%s') {
  58. Rakudo::Internals.initialize-sprintf-handler;
  59. nqp::p6box_s(
  60. nqp::sprintf(nqp::unbox_s($format.Stringy), nqp::list(self))
  61. )
  62. }
  63. method substr($from, $length?) { substr( self,$from,$length) }
  64. method substr-rw(\SELF: $from, $length?) { substr-rw(SELF,$from,$length) }
  65. method uc() {
  66. self.Str.uc
  67. }
  68. method lc() {
  69. self.Str.lc
  70. }
  71. method tc() {
  72. self.Str.tc
  73. }
  74. method fc() {
  75. self.Str.fc
  76. }
  77. method tclc() {
  78. self.Str.tclc
  79. }
  80. method wordcase() { self.Str.wordcase }
  81. method uniname() { uniname(self) }
  82. method uninames() { uninames(self) }
  83. method unival() { unival(self) }
  84. method univals() { univals(self) }
  85. method uniprop(|c) { uniprop(self, |c) }
  86. method uniprop-int(|c) { uniprop-int(self, |c) }
  87. method uniprop-bool(|c) { uniprop-bool(self, |c) }
  88. method uniprop-str(|c) { uniprop-str(self, |c) }
  89. method uniprops(|c) { uniprops(self, |c) }
  90. method unimatch(|c) { unimatch(self, |c) }
  91. method chomp(Cool:D:) { self.Str.chomp }
  92. proto method chop(|) { * }
  93. multi method chop(Cool:D:) { self.Str.chop }
  94. multi method chop(Cool:D: Int() $n) { self.Str.chop($n) }
  95. method ord(--> Int:D) {
  96. self.Str.ord
  97. }
  98. method chr() {
  99. self.Int.chr;
  100. }
  101. method chrs(Cool:D:) { chrs(self.list) }
  102. method ords(Cool:D:) { self.Str.ords }
  103. method flip() {
  104. self.Str.flip
  105. }
  106. method trans(|c) { self.Str.trans(|c) }
  107. method starts-with(Cool:D: |c) {
  108. self.Str.starts-with(|c)
  109. }
  110. method ends-with(Cool:D: |c) {
  111. self.Str.ends-with(|c)
  112. }
  113. method substr-eq(Cool:D: |c) {
  114. self.Str.substr-eq(|c)
  115. }
  116. method contains(Cool:D: |c) {
  117. self.Str.contains(|c)
  118. }
  119. method indices(Cool:D: |c) {
  120. self.Str.indices(|c)
  121. }
  122. method index(Cool:D: |c) {
  123. self.Str.index(|c)
  124. }
  125. method rindex(Cool:D: |c) {
  126. self.Str.rindex(|c)
  127. }
  128. method split(Cool: |c) {
  129. self.Stringy.split(|c);
  130. }
  131. method match(Cool:D: |c) {
  132. $/ := nqp::getlexcaller('$/');
  133. self.Stringy.match(|c)
  134. }
  135. method comb(|c) { self.Str.comb(|c) }
  136. method lines(Cool:D: |c) { self.Str.lines(|c) }
  137. method words(Cool:D: |c) { self.Str.words(|c) }
  138. method subst(|c) {
  139. $/ := nqp::getlexcaller('$/');
  140. self.Stringy.subst(|c);
  141. }
  142. method subst-mutate(Cool:D $self is rw: |c) {
  143. $/ := nqp::getlexcaller('$/');
  144. my $str = $self.Str;
  145. my $match = $str.subst-mutate(|c);
  146. $self = $str;
  147. $match
  148. }
  149. proto method IO(|) { * }
  150. multi method IO(Cool:D:) { IO::Path.new(self) }
  151. multi method IO(Cool:U:) { IO::Path }
  152. method sprintf(*@args) { sprintf(self, @args) };
  153. method printf (*@args) { printf(self, @args) };
  154. method samecase(Cool:D: Cool $pattern) { self.Stringy.samecase($pattern) }
  155. method path() { self.Stringy.IO }
  156. method trim () { self.Stringy.trim };
  157. method trim-leading () { self.Stringy.trim-leading };
  158. method trim-trailing() { self.Stringy.trim-trailing };
  159. method EVAL(*%opts) {
  160. EVAL(self, context => CALLER::, |%opts);
  161. }
  162. multi method Real() {
  163. nqp::if(
  164. nqp::istype((my $numeric := self.Numeric), Failure),
  165. $numeric,
  166. $numeric.Real
  167. )
  168. }
  169. proto method Int(|) { * }
  170. multi method Int() {
  171. nqp::if(
  172. nqp::istype((my $numeric := self.Numeric), Failure),
  173. $numeric,
  174. $numeric.Int
  175. )
  176. }
  177. proto method UInt(|) { * }
  178. multi method UInt() {
  179. my $got := self.Int;
  180. $got < 0
  181. ?? Failure.new(X::OutOfRange.new(
  182. :what('Coercion to UInt'),
  183. :$got,
  184. :range<0..^Inf>))
  185. !! $got
  186. }
  187. method Num() {
  188. nqp::if(
  189. nqp::istype((my $numeric := self.Numeric), Failure),
  190. $numeric,
  191. $numeric.Num
  192. )
  193. }
  194. method Rat() {
  195. nqp::if(
  196. nqp::istype((my $numeric := self.Numeric), Failure),
  197. $numeric,
  198. $numeric.Rat
  199. )
  200. }
  201. method FatRat() {
  202. nqp::if(
  203. nqp::istype((my $numeric := self.Numeric), Failure),
  204. $numeric,
  205. $numeric.FatRat
  206. )
  207. }
  208. }
  209. Metamodel::ClassHOW.exclude_parent(Cool);
  210. proto sub chop(|) { * }
  211. multi sub chop(Cool:D $s --> Str:D) { $s.chop }
  212. multi sub chop(Cool:D $s, Int() $n --> Str:D) { $s.chop($n) }
  213. sub chomp(Cool:D $s --> Str:D) { $s.chomp }
  214. sub flip(Cool $s --> Str:D) { $s.flip }
  215. sub index(Cool $s,$needle,$pos=0) { $s.index($needle,$pos) }
  216. sub lc(Cool $s) { $s.lc }
  217. sub ord(Cool $s) { $s.ord }
  218. sub uc(Cool $s) { $s.uc }
  219. sub tc(Cool $s) { $s.tc }
  220. sub fc(Cool $s) { $s.fc }
  221. sub tclc(Cool $s) { $s.tclc }
  222. sub indices(Cool $s, |c) {
  223. $s.indices(|c);
  224. }
  225. proto sub rindex($, $, $?) is pure { * };
  226. multi sub rindex(Cool $s, Cool $needle, Cool $pos) { $s.rindex($needle, $pos) };
  227. multi sub rindex(Cool $s, Cool $needle) { $s.rindex($needle) };
  228. proto sub ords($) is pure { * }
  229. multi sub ords(Cool $s) { ords($s.Stringy) }
  230. proto sub comb($, $, $?) { * }
  231. multi sub comb(Regex $matcher, Cool $input, $limit = *) { $input.comb($matcher, $limit) }
  232. multi sub comb(Str $matcher, Cool $input, $limit = *) { $input.comb($matcher, $limit) }
  233. multi sub comb(Int:D $matcher, Cool $input, $limit = *) { $input.comb($matcher, $limit) }
  234. proto sub wordcase($) is pure { * }
  235. multi sub wordcase(Str:D $x) {$x.wordcase }
  236. multi sub wordcase(Cool $x) {$x.Str.wordcase }
  237. sub sprintf(Cool $format, *@args) {
  238. CATCH {
  239. when X::Cannot::Lazy {
  240. X::Cannot::Lazy.new(:action('(s)printf')).throw
  241. }
  242. default {
  243. Rakudo::Internals.HANDLE-NQP-SPRINTF-ERRORS($_).throw
  244. }
  245. }
  246. Rakudo::Internals.initialize-sprintf-handler;
  247. @args.elems;
  248. nqp::p6box_s(
  249. nqp::sprintf(nqp::unbox_s($format.Stringy),
  250. nqp::clone(nqp::getattr(@args||[], List, '$!reified'))
  251. )
  252. )
  253. }
  254. sub printf(Cool $format, *@args) { print sprintf $format, @args }
  255. sub samecase(Cool $string, Cool $pattern) { $string.samecase($pattern) }
  256. sub split($pat, Cool $target, |c) { $target.split($pat, |c) }
  257. proto sub chars($) is pure {*}
  258. multi sub chars(Cool $x) { $x.Str.chars }
  259. multi sub chars(Str:D $x) { nqp::p6box_i(nqp::chars($x)) }
  260. multi sub chars(str $x --> int) { nqp::chars($x) }
  261. # These probably belong in a separate unicodey file
  262. proto sub uniname(|) {*}
  263. multi sub uniname(Str:D $str) { $str ?? uniname($str.ord) !! Nil }
  264. multi sub uniname(Int:D $code) { nqp::getuniname($code) }
  265. proto sub uninames(|) {*}
  266. multi sub uninames(Str:D $str) { $str.NFC.map: { uniname($_) } }
  267. proto sub uniprop(|) {*}
  268. multi sub uniprop(Str:D $str, |c) { $str ?? uniprop($str.ord, |c) !! Nil }
  269. multi sub uniprop(Int:D $code) {
  270. nqp::getuniprop_str($code,nqp::unipropcode('General_Category'));
  271. }
  272. multi sub uniprop(Int:D $code, Stringy:D $propname) {
  273. # prop-mappings can be removed when MoarVM bug #448 is fixed...
  274. ## The code below was generated by tools/build/makeUNIPROP.pl6
  275. my constant $prop-mappings = nqp::hash(
  276. 'OGr_Ext','Other_Grapheme_Extend','tc','Titlecase_Mapping',
  277. 'cjkIRG_MSource','kIRG_MSource','Dash','Dash','Pat_Syn','Pattern_Syntax',
  278. 'IDST','IDS_Trinary_Operator','IDC','ID_Continue','Dia','Diacritic',
  279. 'Cased','Cased','hst','Hangul_Syllable_Type','QMark','Quotation_Mark',
  280. 'Radical','Radical','NFD_QC','NFD_Quick_Check','jt','Joining_Type',
  281. 'cf','Case_Folding','cjkIRG_TSource','kIRG_TSource','sc','Script',
  282. 'SD','Soft_Dotted','CWCM','Changes_When_Casemapped',
  283. 'cjkOtherNumeric','kOtherNumeric','scf','Simple_Case_Folding',
  284. 'sfc','Simple_Case_Folding','isc','ISO_Comment','na1','Unicode_1_Name',
  285. 'Lower','Lowercase','Join_C','Join_Control','JSN','Jamo_Short_Name',
  286. 'bc','Bidi_Class','jg','Joining_Group','dm','Decomposition_Mapping',
  287. 'lc','Lowercase_Mapping','cjkIRG_USource','kIRG_USource',
  288. 'NFKC_CF','NFKC_Casefold','slc','Simple_Lowercase_Mapping',
  289. 'InSC','Indic_Syllabic_Category','XO_NFC','Expands_On_NFC',
  290. 'XO_NFD','Expands_On_NFD','cjkAccountingNumeric','kAccountingNumeric',
  291. 'Upper','Uppercase','WSpace','White_Space','space','White_Space',
  292. 'cjkIRG_VSource','kIRG_VSource','STerm','Sentence_Terminal',
  293. 'NFKD_QC','NFKD_Quick_Check','CWT','Changes_When_Titlecased','Math','Math',
  294. 'uc','Uppercase_Mapping','NFKC_QC','NFKC_Quick_Check','SB','Sentence_Break',
  295. 'stc','Simple_Titlecase_Mapping','Alpha','Alphabetic',
  296. 'CE','Composition_Exclusion','NChar','Noncharacter_Code_Point',
  297. 'OAlpha','Other_Alphabetic','XIDC','XID_Continue','age','Age',
  298. 'cjkPrimaryNumeric','kPrimaryNumeric','OIDS','Other_ID_Start',
  299. 'UIdeo','Unified_Ideograph','FC_NFKC','FC_NFKC_Closure','CI','Case_Ignorable',
  300. 'Hyphen','Hyphen','nv','Numeric_Value','CWKCF','Changes_When_NFKC_Casefolded',
  301. 'XO_NFKD','Expands_On_NFKD','InPC','Indic_Positional_Category',
  302. 'dt','Decomposition_Type','cjkIICore','kIICore','Bidi_M','Bidi_Mirrored',
  303. 'CWU','Changes_When_Uppercased','IDS','ID_Start','Gr_Ext','Grapheme_Extend',
  304. 'XIDS','XID_Start','XO_NFKC','Expands_On_NFKC','OUpper','Other_Uppercase',
  305. 'OMath','Other_Math','Gr_Link','Grapheme_Link','Bidi_C','Bidi_Control',
  306. 'DI','Default_Ignorable_Code_Point','CWCF','Changes_When_Casefolded',
  307. 'cjkIRG_GSource','kIRG_GSource','WB','Word_Break','NFC_QC','NFC_Quick_Check',
  308. 'cjkIRG_JSource','kIRG_JSource','ODI','Other_Default_Ignorable_Code_Point',
  309. 'LOE','Logical_Order_Exception','bpb','Bidi_Paired_Bracket',
  310. 'PCM','Prepended_Concatenation_Mark','OLower','Other_Lowercase',
  311. 'OIDC','Other_ID_Continue','VS','Variation_Selector','Ext','Extender',
  312. 'Comp_Ex','Full_Composition_Exclusion','IDSB','IDS_Binary_Operator',
  313. 'nt','Numeric_Type','cjkCompatibilityVariant','kCompatibilityVariant',
  314. 'suc','Simple_Uppercase_Mapping','Term','Terminal_Punctuation',
  315. 'lb','Line_Break','cjkIRG_HSource','kIRG_HSource','ea','East_Asian_Width',
  316. 'AHex','ASCII_Hex_Digit','cjkIRG_KSource','kIRG_KSource',
  317. 'Pat_WS','Pattern_White_Space','Hex','Hex_Digit',
  318. 'cjkIRG_KPSource','kIRG_KPSource','bpt','Bidi_Paired_Bracket_Type',
  319. 'gc','General_Category','GCB','Grapheme_Cluster_Break',
  320. 'Gr_Base','Grapheme_Base','na','Name','scx','Script_Extensions',
  321. 'Ideo','Ideographic','Name_Alias','Name_Alias','blk','Block','Dep','Deprecated',
  322. 'CWL','Changes_When_Lowercased','bmg','Bidi_Mirroring_Glyph',
  323. 'cjkRSUnicode','kRSUnicode','Unicode_Radical_Stroke','kRSUnicode',
  324. 'URS','kRSUnicode','ccc','Canonical_Combining_Class',
  325. );
  326. my constant $prefs = nqp::hash(
  327. 'Other_Grapheme_Extend','B','Titlecase_Mapping','tc','Dash','B',
  328. 'Emoji_Modifier_Base','B','Emoji_Modifier','B','Pattern_Syntax','B',
  329. 'IDS_Trinary_Operator','B','ID_Continue','B','Diacritic','B','Cased','B',
  330. 'Hangul_Syllable_Type','S','Quotation_Mark','B','Radical','B',
  331. 'NFD_Quick_Check','S','Joining_Type','S','Case_Folding','S','Script','S',
  332. 'Soft_Dotted','B','Changes_When_Casemapped','B','Simple_Case_Folding','S',
  333. 'ISO_Comment','S','Lowercase','B','Join_Control','B','Bidi_Class','S',
  334. 'Joining_Group','S','Decomposition_Mapping','S','Lowercase_Mapping','lc',
  335. 'NFKC_Casefold','S','Simple_Lowercase_Mapping','S',
  336. 'Indic_Syllabic_Category','S','Expands_On_NFC','B','Expands_On_NFD','B',
  337. 'Uppercase','B','White_Space','B','Sentence_Terminal','B',
  338. 'NFKD_Quick_Check','S','Changes_When_Titlecased','B','Math','B',
  339. 'Uppercase_Mapping','uc','NFKC_Quick_Check','S','Sentence_Break','S',
  340. 'Simple_Titlecase_Mapping','S','Alphabetic','B','Composition_Exclusion','B',
  341. 'Noncharacter_Code_Point','B','Other_Alphabetic','B','XID_Continue','B',
  342. 'Age','S','Other_ID_Start','B','Unified_Ideograph','B','FC_NFKC_Closure','S',
  343. 'Case_Ignorable','B','Hyphen','B','Numeric_Value','nv',
  344. 'Changes_When_NFKC_Casefolded','B','Expands_On_NFKD','B',
  345. 'Indic_Positional_Category','S','Decomposition_Type','S','Bidi_Mirrored','B',
  346. 'Changes_When_Uppercased','B','ID_Start','B','Grapheme_Extend','B',
  347. 'XID_Start','B','Expands_On_NFKC','B','Other_Uppercase','B','Other_Math','B',
  348. 'Grapheme_Link','B','Bidi_Control','B','Default_Ignorable_Code_Point','B',
  349. 'Changes_When_Casefolded','B','Word_Break','S','NFC_Quick_Check','S',
  350. 'Other_Default_Ignorable_Code_Point','B','Logical_Order_Exception','B',
  351. 'Prepended_Concatenation_Mark','B','Other_Lowercase','B',
  352. 'Other_ID_Continue','B','Variation_Selector','B','Extender','B',
  353. 'Full_Composition_Exclusion','B','IDS_Binary_Operator','B','Numeric_Type','S',
  354. 'kCompatibilityVariant','S','Simple_Uppercase_Mapping','S',
  355. 'Terminal_Punctuation','B','Line_Break','S','East_Asian_Width','S',
  356. 'ASCII_Hex_Digit','B','Pattern_White_Space','B','Hex_Digit','B',
  357. 'Bidi_Paired_Bracket_Type','S','General_Category','S',
  358. 'Grapheme_Cluster_Break','S','Grapheme_Base','B','Name','na','Ideographic','B',
  359. 'Block','S','Emoji_Presentation','B','Emoji','B','Deprecated','B',
  360. 'Changes_When_Lowercased','B','Bidi_Mirroring_Glyph','bmg',
  361. 'Canonical_Combining_Class','S',
  362. );
  363. ## End generated code
  364. $propname := nqp::atkey($prop-mappings, $propname) if nqp::existskey($prop-mappings,$propname);
  365. my $prop := nqp::unipropcode($propname);
  366. given nqp::atkey($prefs, $propname) {
  367. when 'S' { nqp::getuniprop_str($code,$prop) }
  368. when 'I' { nqp::getuniprop_int($code,$prop) }
  369. when 'B' { nqp::p6bool(nqp::getuniprop_bool($code,$prop)) }
  370. when 'lc' { nqp::lc( nqp::chr( nqp::unbox_i($code) ) ) }
  371. when 'tc' { nqp::tc( nqp::chr( nqp::unbox_i($code) ) ) }
  372. when 'uc' { nqp::uc( nqp::chr( nqp::unbox_i($code) ) ) }
  373. when 'na' { nqp::getuniname($code) }
  374. when 'nv' { unival($code) }
  375. when 'bmg' {
  376. my int $bmg-ord = nqp::getuniprop_int($code, $prop);
  377. $bmg-ord ?? nqp::chr($bmg-ord) !! '';
  378. }
  379. default {
  380. my $result = nqp::getuniprop_str($code,$prop);
  381. if $result ne '' { nqp::bindkey($prefs, $propname, 'S'); $result }
  382. else { nqp::bindkey($prefs, $propname, 'I'); nqp::getuniprop_int($code,$prop) }
  383. }
  384. }
  385. }
  386. # Unicode functions
  387. proto sub uniprop-int(|) {*}
  388. multi sub uniprop-int(Str:D $str, Stringy:D $propname) {
  389. $str ?? uniprop-int($str.ord, $propname) !! Nil }
  390. multi sub uniprop-int(Int:D $code, Stringy:D $propname) {
  391. nqp::getuniprop_int($code,nqp::unipropcode($propname));
  392. }
  393. proto sub uniprop-bool(|) {*}
  394. multi sub uniprop-bool(Str:D $str, Stringy:D $propname) {
  395. $str ?? uniprop-bool($str.ord, $propname) !! Nil
  396. }
  397. multi sub uniprop-bool(Int:D $code, Stringy:D $propname) {
  398. nqp::p6bool(nqp::getuniprop_bool($code,nqp::unipropcode($propname)));
  399. }
  400. proto sub uniprop-str(|) {*}
  401. multi sub uniprop-str(Str:D $str, Stringy:D $propname) {
  402. $str ?? uniprop-str($str.ord, $propname) !! Nil
  403. }
  404. multi sub uniprop-str(Int:D $code, Stringy:D $propname) {
  405. nqp::getuniprop_str($code,nqp::unipropcode($propname));
  406. }
  407. proto sub uniprops(|) {*}
  408. multi sub uniprops(Str:D $str, Stringy:D $propname = "General_Category") {
  409. $str.ords.map: { uniprop($_, $propname) }
  410. }
  411. proto sub unival(|) {*}
  412. multi sub unival(Str:D $str) { $str ?? unival($str.ord) !! Nil }
  413. multi sub unival(Int:D $code) {
  414. state $nuprop = nqp::unipropcode("Numeric_Value_Numerator");
  415. state $deprop = nqp::unipropcode("Numeric_Value_Denominator");
  416. my $nu = nqp::getuniprop_str($code, $nuprop);
  417. my $de = nqp::getuniprop_str($code, $deprop);
  418. !$de || $de eq '1' ?? $nu.Int !! $nu / $de;
  419. }
  420. proto sub univals(|) {*}
  421. multi sub univals(Str:D $str) { $str.ords.map: { unival($_) } }
  422. proto sub unimatch(|) {*}
  423. multi sub unimatch(Str:D $str, |c) { $str ?? unimatch($str.ord, |c) !! Nil }
  424. # This multi below can be removed when MoarVM bug #448 is fixed
  425. multi sub unimatch(Int:D $code, Stringy:D $pvalname, Stringy:D $propname) {
  426. uniprop($code, $propname) eq $pvalname;
  427. }
  428. multi sub unimatch(Int:D $code, Stringy:D $pvalname, Stringy:D $propname = $pvalname) {
  429. my $prop := nqp::unipropcode($propname);
  430. nqp::p6bool(nqp::matchuniprop($code,$prop,nqp::unipvalcode($prop,$pvalname)));
  431. }