mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-04 04:08:19 +00:00
|
-> where
This commit is contained in:
parent
fd846b9a7a
commit
cb08225bf0
117 changed files with 637 additions and 612 deletions
|
@ -602,7 +602,13 @@ fn variable_to_string(
|
|||
ctx.able_variables.sort();
|
||||
ctx.able_variables.dedup();
|
||||
for (i, (var, abilities)) in ctx.able_variables.into_iter().enumerate() {
|
||||
buf.push_str(if i == 0 { " | " } else { ", " });
|
||||
if i == 0 {
|
||||
buf.push(' ');
|
||||
buf.push_str(roc_parse::keyword::WHERE)
|
||||
} else {
|
||||
buf.push(',');
|
||||
}
|
||||
buf.push(' ');
|
||||
buf.push_str(var);
|
||||
buf.push(' ');
|
||||
buf.push_str(roc_parse::keyword::IMPLEMENTS);
|
||||
|
|
|
@ -1760,7 +1760,7 @@ pub enum Type {
|
|||
}
|
||||
|
||||
/// A lambda set under an arrow in a ability member signature. For example, in
|
||||
/// Default has default : {} -> a | a implements Default
|
||||
/// Default has default : {} -> a where a implements Default
|
||||
/// the unspecialized lambda set for the arrow "{} -> a" would be `a:default:1`.
|
||||
///
|
||||
/// Lambda sets in member signatures are never known until those members are specialized at a
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue