mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-23 17:41:41 +00:00
Change function's function param to correct syntax (#4065)
Ref: https://dart.dev/guides/language/sound-problems Co-authored-by: ven <vendethiel@hotmail.fr>
This commit is contained in:
parent
e50a0fbacc
commit
c5e7af574b
@ -79,7 +79,8 @@ example1() {
|
|||||||
|
|
||||||
/// Anonymous functions don't include a name
|
/// Anonymous functions don't include a name
|
||||||
example2() {
|
example2() {
|
||||||
nested1(fn) {
|
//// Explicit return type.
|
||||||
|
nested1(void Function() fn) {
|
||||||
fn();
|
fn();
|
||||||
}
|
}
|
||||||
nested1(() => print("Example2 nested 1"));
|
nested1(() => print("Example2 nested 1"));
|
||||||
|
Loading…
Reference in New Issue
Block a user