dunham
Lean4 takes this to an extreme and has "syntax categories" (e.g. expression), each of which has something like a pratt parser. Ambiguity is broken by taking the option that makes the most progress, and it is made efficient by memoization. You can add syntax at compile time, down to the lexing level. There is an example that adds HTML-like syntax and uses it later in the same file.
https://github.com/leanprover/lean4/blob/0f2eaa6e776255083f9...
(I'm not saying changing the language on the fly is a good idea, but it's interesting that they pulled it off.)
I was afraid of that. I grabbed a 2024-04-20 copy as a backup, in case it turned to slop, but I suspected it might be tainted already.
But, as an adult, I don't really make the time for games anymore. I've been sitting on Baldur's Gate 3 (maybe an hour or two in) for years.
It's TeX in wasm implemented by writing a pascal to wasm compiler, which seemed like a novel approach. (TeX is written in pascal and typically translated to C before building.)
TeX itself is a 500kb wasm file (compresses to 90k), but the images get much bigger with things like LaTeX pre-loaded.
(The author uses it to run tikz in a browser in this repository: https://github.com/kisonecat/tikzjax)
But I've found that a lot of news sites are bearable with javascript disabled. On chrome desktop, you can do that per site via the site settings in the location bar. On iOS, I'm using Quiche browser. It's subscription, but it can disable javascript per site and has auto dark mode functionality.
These days, I try avoid them outside of makefiles.
https://news.ycombinator.com/item?id=22336284
It is one person and one project, but I found it interesting to read about his experience.
I like Go, but I probably would have tried Rust first because I want pattern matching when implementing languages.
Sharing aside, I imagine a plain text format would also be helpful for version control.
Essentially a digital pinboard, it was an interesting experiment in "designed for tablet" UX and was developed far enough to be an app. The gesture based UX, nested board, PDF reader, and transclusion of PDF fragments are all interesting ideas.
[1]: https://www.inkandswitch.com/muse/ [2]: https://allume.com/
"Crisp-roasted maitake mushrooms with garlicky labneh, fresh local raab, warm Middle Eastern Spices and Mama Lil's spicy pickled peppers on a toasted Ciabatta roll."
The raab and the mushrooms (sliced into sheets) were seared crisp. I substituted harissa mixed with mayo or greek yogurt for the sauce.
On the not safe front, I recently learned that volunteer squash can be very bad for you - I guess the poisonous varieties are genetically close to the edible ones.
Oh and my grandfather foraged and ate Gyromitra esculenta mushrooms. (I've eaten them as a child, I would not eat them now.) They are very bad news. The way he processed them made them safe. But he said he soaked them in salted water to "get the bugs out" - he did not know they were toxic.
https://www.electronjs.org/docs/latest/api/app#apprequestsin...
and handle this event:
https://www.electronjs.org/docs/latest/api/app#event-second-...
I believe macos is the only OS that enforces single instance by default. If you start xterm five times on linux, you get five independent xterm processes.
foo x y = do a <- something
pure somethingElse
Renaming `x` to `xxx` would push the indented block in and the subsequent lines would have to be indented too.Similarly:
foo x y = let a = something
b = anotherThing
in somethingElse
Elm avoids this by requiring an newline after the `do` and `let` (if the `let` has multiple assignments).Edit: This was brought to my attention by an Idris style guide that said: "Indent so that alpha conversion always works with a simple search and replace. In general this would mean starting a new line when starting a new level of indentation."
That said, it is hard-mode:
- You'll have to figure out how to parse it.
- If you want editor support, it's a pain to get tree-sitter to handle it.
- You may not be able to pull off editor operations like "rename" without implementing a pretty printer (a rename might affect indentation).
I think it is helpful for crude error recovery. On parse error, my language will simply skip to the next column 0 token and parse another declaration.
I did not do this (hindsight), but I would recommend arranging the grammar so you only get indented blocks in cases where the previous line ends in a keyword that introduces it. I think python has a trailing `:` every time indentation is introduced, and Elm does this too - in statements like `let` you need a newline after the `let` to get the multi-declaration version. (This addresses the rename issue.)
https://gist.github.com/dunhamsteve/59f5e6b9a4bc69039853674d...
Elm served its purpose for me - an example of a small language with great tooling and error messages. And the strictness was helpful in learning to do things the "proper" way in the Elm model, even if I did reach for escape hatches in later projects. E.g. writing a notion-like application in Elm, I had to walk through my data twice - once to render it and another time to collect cache misses. With hyperapp, I broke purity a little and accumulated the information on the side.
It looks like the live demo is no longer up, but it did run latex in the browser and render the dvi output to html. The wasm for TeX is about 495kb / 88kb compressed, but the memory image for LaTeX was a bit larger.
I recently discovered that the author of gzip still retains that 90's feel on his home page: http://gailly.net/
Linux resolved this issue, but to work around it on windows, I changed my cursor to an animated dinosaur, which was built into the OS and had the side-effect of disabling the hardware cursor.
For many sites, especially news sites, I toggle javascript off. It's reasonably easy to do per site in chrome (click left of location bar and "site settings"). I don't know if there is an easy way to do this per site in firefox.
So far I've stuck with chrome for a few reasons:
- Mozilla doesn't implement desktop PWA and has cancelled the project. I use this. - Mozilla was using about twice as much memory as chrome. (I need to revisit this, Chrome seems to have gotten fatter.) - Safari is a royal pain to write your own extensions (last I checked you need to create an application and bundle the extension into it). - I like the multiple profiles in Chrome to sandbox things like my google login. There may be a firefox equivalent, however.