• 1 Post
  • 15 Comments
Joined 1 year ago
cake
Cake day: November 1st, 2023

help-circle


  • Well you’re writing a Compiler with extra features to tell you where compilation failed but without actually executing the code. If the language you are trying to implement has defined a BNF for its language its quite doable and depending on the features you want to implement almost easy. There are BNF interpreters and chumsky e.g. is close to reading like a BNF. But if you’re building a language where you gotta find out the rules yourself it can take a while and finding all the edgecases can be a problem… But the project is big enough that most probably don’t finish theirs


  • I am currently writing an LSP for the shaderscript used in Godot. Its close to glsl but some differences make me not wanting to just copy paste a glsl one. I am currently trying to wrap my head around chumsky. I am coming from a lot of c code and my head doesnt work like chumsky does, so it has its ups and downs, but lexer for glsl and lexer, parser and like half oft the evaluator for the preprocessor are done and working😊








  • Peer2peer connections are very difficult. Mainly because clients are behind a NAT which allows only connections from inside to outside. So when a client wants to connect to another client one connection comes from outside and is blocked. There is a “bug” called NAT holepunching to still connect but that’s not a trivial task and doesn’t work on all setups. I recently tried out webRTC for a multiplayer game but I still don’t know what to do with people where that connection can’t be established. SteamAPI has a P2P feature as well, and when they can’t establish a p2p connection they just silently route the packets over their servers.