mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-04 18:58:36 +00:00
Experimental support for named callback parameters
And use that in the lsp/ui implementation instead of comments. This is only a parser support for now, the name is otherwise unused. Hence I rather keep that experimental.
This commit is contained in:
parent
cb72e48aa4
commit
3a59950751
11 changed files with 97 additions and 40 deletions
|
@ -343,7 +343,9 @@ declare_syntax! {
|
|||
RepeatedElement -> [ ?DeclaredIdentifier, ?RepeatedIndex, Expression , SubElement],
|
||||
RepeatedIndex -> [],
|
||||
ConditionalElement -> [ Expression , SubElement],
|
||||
CallbackDeclaration -> [ DeclaredIdentifier, *Type, ?ReturnType, ?TwoWayBinding ],
|
||||
CallbackDeclaration -> [ DeclaredIdentifier, *CallbackDeclarationParameter, ?ReturnType, ?TwoWayBinding ],
|
||||
// `foo: type` or just `type`
|
||||
CallbackDeclarationParameter -> [ ?DeclaredIdentifier, Type],
|
||||
Function -> [DeclaredIdentifier, *ArgumentDeclaration, ?ReturnType, CodeBlock ],
|
||||
ArgumentDeclaration -> [DeclaredIdentifier, Type],
|
||||
/// `-> type` (but without the ->)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue