-
Notifications
You must be signed in to change notification settings - Fork 22
Open
Description
Look at this error message:
basicTypesBundle.grace[14:24]: Syntax error: a type argument list containing a '⟦' must have a matching '⟧'.
13: matches (value:Object) → Boolean
14: & (other:Type⟦U where U <: Type⟧) → Type⟦T&U⟧ // answers the join (Self & other)
-----------------------------^
The arrow points to the space before the where. I believe that the where is fine (modulo declaring U somewhere; see language design issue #156). However, miningrace's parser is not expecting a where in this type parameter.
The problem arises because minigrace is confused about the difference between type arguments and type parameters. Come to think if it: I'm confused too. In the above example, the Type... after parameter other: is an applied occurence of a type expression — in other words, a type argument — so everything in it should already be defined. So: can type parameters be qualified by where clauses in method signatures? Should the where go somewhere else?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels