News for hackers. Stuff that matters.
Re:Graphical User Interface Using Flutter in Embedded System... by caditinpiscinam on Wednesday October 28, 2020 @08:34PM (#24925804)
Mine too. It does gradual typing better than any other language I've tried.
Re:Graphical User Interface Using Flutter in Embedded System... by SV_BubbleTime on Thursday October 29, 2020 @12:23AM (#24927192)
I think this means sometimes static sometimes dynamic. but can you explain some use cases for this?

I am strongly in favor of static, coming from C.

Re:Graphical User Interface Using Flutter in Embedded System... by caditinpiscinam on Thursday October 29, 2020 @05:25PM (#24936115)
A perfect static type checker would distinguish between valid and invalid programs in all cases. In practice, static type checkers are conservative and occasionally reject valid programs. Gradual typing gives you a way out in these situations -- just like how macros in C can provide type-generic functionality.

A sufficiently rich type system (with tuples, union types, traits, generics, higher-kinded types, etc) can lessen the need for a dynamic escape hatch. In the end though, the occasional use of dynamic typing can be easier to reason about.

Re:Graphical User Interface Using Flutter in Embedded System... by mhoad on Thursday October 29, 2020 @04:35AM (#24928408)
Everything is static by default unless you explicitly opt to declare a variable as dynamic for specific use cases.

Also worth noting that Dart now also includes fully sound null safety https://dart.dev/null-safety

Re:Graphical User Interface Using Flutter in Embedded System... by scns on Thursday October 29, 2020 @02:25AM (#24927838)
If you want to convert your data to JSON you put it into a Map<String, Dynamic>.