Raku++ Specification
How Raku++ behaves — every feature explained, with runnable, verified examples.
337 features across 129 pages · every example verified against Raku++, Rakudo, and the in-browser engine
Raku Rules — the exhaustive reference → See the full Roast conformance map → Dashboard → Where Raku++ excels →
FullPartialDivergentNot implemented
Literals & quoting9
Variables & sigils7
Operators23
- The ternary operator ?? !!
- Arithmetic operators
- Bitwise operators — +& +| +^ +< +>
- min / max / ≅
- String operators ~ and x
- List repetition xx
- Slices
- Subscript adverbs — :exists / :delete
- Comparison & chaining
- Equivalence & identity — eqv / ===
- Logical operators
- Smartmatch ~~
- andthen & orelse
- The range operator ..
- The sequence operator ...
- Junctions any / all / none
- Set operators
- Metaoperators — Z, X, R & hyper
- Assignment operators
- The Whatever star *
- Feed operators ==> and <==
- Custom operators
- The slip operator |
Control flow9
Subroutines & signatures14
- Defining subroutines
- Return types
- Parameters — optional, default & slurpy
- Named parameters & arguments
- where constraints
- Multi dispatch
- Re-dispatch — callsame, nextsame & friends
- Destructuring parameters
- proto
- Coercion-type parameters Int()
- Blocks & placeholder parameters
- Currying with .assuming
- Closures
- State variables
Types, classes & roles13
Phasers2
Concurrency1
Regexes & grammars13
- Matching with ~~
- Captures
- Conjunction & capture aliases
- Substitution
- Substitution with a closure
- prematch & postmatch — text around a match
- Backreferences — $0 inside a pattern
- Regex adverbs — :i / :s / :g
- Quantifiers, anchors & alternation
- Separated quantifiers % and %%
- Named regexes as subrules
- Lookahead & lookbehind assertions
- Grammars
Built-in routines12
- say / print / put
- map / grep / sort
- Reductions — sum, min, max & [OP]
- join / split / words / first
- Laziness — lazy, eager & infinite lists
- Math functions
- Trigonometry — sin, cos, tan & friends
- Rounding — floor / ceiling / round / truncate
- Coercions
- Testing — use Test
- File & process IO
- sprintf & fmt — formatting
Methods by type26
- Universal methods
- String methods
- Character translation — trans with ranges
- String tests & search
- Case methods
- List methods
- Deduplication — unique / squish / repeated
- minpairs / maxpairs / pairup / flatmap
- min / max / minmax
- Splitting a string
- categorize — multi-key grouping
- samecase
- Hash methods
- Trimming — trim / chomp / chop
- Hash operations
- Numeric methods
- succ & pred — increment
- parse-base — read a number in any radix
- Unicode & graphemes
- Complex methods
- Combinations & permutations
- Indexed list access
- Reshaping lists — flat, rotor, scan
- rotate
- Array mutation — push / pop / splice
- polymod — successive division