Accept prefix notation for writing the types of str/~ and friends.
This commit is contained in:
parent
acb86921a6
commit
2ea9c8df0f
37 changed files with 198 additions and 147 deletions
|
|
@ -4,7 +4,7 @@ fn main() {
|
|||
let cheese = "roquefort";
|
||||
let carrots = @"crunchy";
|
||||
|
||||
fn@(tasties: @str, macerate: fn(str)) {
|
||||
fn@(tasties: @str/~, macerate: fn(str)) {
|
||||
macerate(*tasties);
|
||||
} (carrots, |food| {
|
||||
let mush = food + cheese;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue