Gossamer: a Rust-flavoured language with real goroutines and pause-free memory
#HackerNews #Gossamer #Rust #Goroutines #MemoryManagement #ProgrammingLanguage
Gossamer: a Rust-flavoured language with real goroutines and pause-free memory
#HackerNews #Gossamer #Rust #Goroutines #MemoryManagement #ProgrammingLanguage
I find myself holding perhaps strange opinions.
Suppose there is some language that has a type for integers the platform’s native pointer width, like size_t or usize.
Suppose there is also a mechanism for getting the bit-width of a type, like sizeof.
Then, which of these two is better?
A constant named e.g. USIZEWIDTH that is defined to hold the width of usize, or
A macro or function defined using sizeof to do the same thing?
Obviously you can always use sizeof yourself. This would be an abbreviation.
Strangely, I find myself preferring the function or macro. It feels like this makes the fact that it does in fact represent the width of usize less coincidental.
But, of course, the function or macro is also coincidental. Just as the USIZEWIDTH value could be (accidentally) wrong, the function or macro could be (accidentally) defined the wrong way.
I believe that the reason for this is that a change in the platform (i.e. a change in the compiler) would automatically update the function or macro’s output. An accidental mismatch for the constant wouldn’t require actively meddling with its definition at all.
FuncSug Playground: https://cl4cnam.github.io/try_FuncSug
Hello 🙂,
How do you handle events?
Here is a little comparison using an example: programming a button that toggles a text.
▶️ Event-driven (JavaScript/DOM, Gtk, Qt...)
------------
label := 'state 1'
on click:
label := (if label = 'state2' then 'state1' else 'state2')
▶️ Immediate mode (ImGui, G'MIC...)
--------------
setup:
label := 'state1'
draw:
if click:
label := (if label = 'state2' then 'state1' else 'state2')
▶️ FuncSug
--------
while true:
label := 'state1'
await click
label := 'state2'
await click
An example 'Cross the River': https://cl4cnam.github.io/try_FuncSug?example=crossRiverFish
FuncSug playground: https://cl4cnam.github.io/try_FuncSug
Learn computer science with Nanowar of Steel.
After Java these Power Point slides will take you to the army of Kotlin.
Nanowar of Steel - Kotlin
https://youtu.be/BsfXZjKLT9A?si=bFUf8EdXI-BB8T97
#music #metal #powermetal #musicvideo #video #computerscience #informatic #programminglanguage #kotlin #slide #powerpoint #Nanowar #NanowarOfSteel

XOScript 1.5.18 has been released.
New in this release:
- Improved security against DDoS attacks
- Various performance improvements
- Experimental support for runtime object snapshotting
https://xoscript.com/download.xo #xoscript #programminglanguage
La programmation événementielle n'est pas une panacée. Cela est connu depuis longtemps. Il y a une vingtaine d'année, l'article d'Andreas Gustafsson (https://spawn-queue.acm.org/doi/pdf/10.1145/1105664.1105678) l'expliquait bien. Qu'en est-il aujourd'hui ? Pourquoi la programmation événementielle est-elle encore présentée de nos jours comme une évidence ou, au mieux, comme un mal nécessaire ?