The Toit Language

104 posts

The Toit Language banner
The Toit Language

The Toit Language

@toitlang

Katılım Ekim 2018
12 Takip Edilen181 Takipçiler
The Toit Language
The Toit Language@toitlang·
Add BLAKE2S crypto hash support. Start BLE services in one go. Improve BLE resource management. Add 'close' to the BLE adapter. Fix RMT on esp32s3 (and other variants). github.com/toitlang/toit/…
English
1
0
2
300
The Toit Language
The Toit Language@toitlang·
Add reader.do --lines [block]. Fix byte-array size checks in firmware-copy primitive. Fix subtle GC issues with TLS buffers. Fix toitdoc generation for packages. Fix yaml text starting with Q. Fix yaml indented blocks. Fix yaml implicit keys. github.com/toitlang/toit/…
English
0
0
1
186
The Toit Language
The Toit Language@toitlang·
Add 'toit pkg' and 'toit snapshot' commands. Don't use tasks to wait for services to appear. Handle 'werror' when doing 'toit.compile --analyze'. Stream JSON and YAML output onto a Writer. Change close-X to mark-closed on io.Reader and io.Writer. github.com/toitlang/toit/…
English
0
0
2
161
The Toit Language
The Toit Language@toitlang·
Introduce new io library. Optimize getting size of builtin collections. Avoid spinning up too many native threads on host platforms. Avoid lock contention on scavenge on host platforms. Start to bring back the toit executable. Roll esp-idf to latest v5.0. github.com/toitlang/toit/…
English
0
0
3
102
The Toit Language retweetledi
Erik
Erik@erikcorry·
Compare the simple and wrong syntax with the correct but verbose syntax: a = [[]] * 4 b = [ [] for _ in range(4) ] In Toit you pass a block (small fn introduced with a colon) to the List constructor. c := List 4: []
English
0
1
1
158
The Toit Language
The Toit Language@toitlang·
Going to ban this space-less function call. We need this syntax for raw strings.
The Toit Language tweet media
English
0
1
1
200
The Toit Language retweetledi
Raveesh Agarwal
Raveesh Agarwal@raveesh_me·
Took an immense amount of self discipline and focus, so yesterday ends(at 1am today) with an esp32 running a @toitlang container with capacitive moisture sensor sending moisture levels every 3 seconds to a local mqtt broker on a raspberry Pi which I can look at through my phone.
English
1
1
2
288
The Toit Language retweetledi
Erik
Erik@erikcorry·
On the device (an @m5stack).
English
1
1
3
235
The Toit Language retweetledi
Erik
Erik@erikcorry·
New version of @toitlang's pixel_display library is getting sliders. We have PNG support, but no PNGs were used here, just gradients like the ones we know from the web.
Erik tweet media
English
1
1
3
541
The Toit Language
The Toit Language@toitlang·
In the Toit weak map proposal the lifetime of the key is not relevant, so it can be a string or an int, but the value can be automatically removed from the map if it is not otherwise reachable and we need the memory.
English
0
0
1
108
The Toit Language
The Toit Language@toitlang·
Looks like I'm getting weak maps, but not with the JavaScript semantics. In JavaScript WeakMap the key keeps the value alive, but when the key is collected by the GC, the key-value pair are removed from the map, and the value may become GC-able.
Erik@erikcorry

I decided I needed a weakly retaining hash map for my latest #toitlang project. It can be used to cache values that can be recalculated. The values can be nulled out during GC if the objects are not reachable in other ways and there is memory pressure. github.com/toitlang/toit/…

English
1
1
0
196