beneroth changed the topic of #picolisp to: PicoLisp language | The scalpel of software development | Channel Log: https://libera.irclog.whitequark.org/picolisp | Check www.picolisp.com for more information
ygrek has quit [Remote host closed the connection]
DKordic has quit [Remote host closed the connection]
beneroth has joined #picolisp
geri has joined #picolisp
<geri> i hath returned, probably with a new picolisp enjoyer xd
<geri> i wrote another pil inspired interpreter and like more i do it more i come to appreciate all the design decisions that were put into it
<abu[7]> Hi geri!
<geri> hey-hey :D
<abu[7]> Is it a Lisp?
<geri> yeah
<abu[7]> ๐Ÿ‘
<geri> functions are just lists, quote returns all its arguments, fexps, all that jazz
<geri> my brain got pico'd cause i really dont want to write a traditional lisp at all
<abu[7]> Good :)
<geri> im glad i wrote it in python cause rewriting eval and apply in cl is like 10 minutes
<geri> also for fun i made the reader bash-like
<geri> so all symbols were python strings, right
<geri> quotation is like in bash, so Hello == "Hello"
<geri> you can do "Hello world" and its a symbol
<geri> and you can do Hello" world "cause" "why" "not => "Hello world cause why not"
<geri> its horrifying and i love it
<abu[7]> cool
<geri> do transient symbols have a properly attached to them to be self-evaluating by default?
<abu[7]> No, it is simply the value being initialized to itself
<geri> oh right
<abu[7]> Like T, NIL etc
<geri> my environment was represented as a list of dictionaries cause i couldnt figure out interning stuff for symbols
<geri> could probably change it now but eh
<abu[7]> In Ersatz I used a HashMap<String,Symbol> for that
<abu[7]> similas I think
<geri> yeah, mine just mapped strings to values in env instead of strings to symbols when interning (there was no interning in fact)
<abu[7]> ok
<geri> what does ersatz mean btw?
<abu[7]> It is a german word for "replacement"
<abu[7]> a bit negative
<geri> i realized i can go rewrite picolisp in some other language and in the end we'd have an impl for like every platform :D
<geri> conquer the world B)
<geri> i was looking some stuff up on gc's and was like "well, if you have to gc a string, don't you need to loop through the whole thing to see where it ends? but if all elements are of same width... like... cells......."
<geri> :D
sirppi has joined #picolisp
<sirppi> hello people!
<sirppi> geriii
<geri> B)
<geri> caught another one
<sirppi> cmon man picolisp sounds dope as fuk
<geri> it does
<geri> if you thought it couldnt get any better
<geri> abu[7]: is pico's author btw, seems afk for a bit tho
<sirppi> wow ive never seen anyone take android so seriously
<sirppi> abu[7]: RESPECT.
<geri> i wrote half of my interpreter on my phone cause i was bored while camping
<beneroth> ahoy sirppi
<beneroth> welcome here
<sirppi> hi there!
<beneroth> btw. abu[7] is now using android as his main dev machine. xD
<beneroth> I still like bigger computers
<sirppi> odd choice
<beneroth> sirppi, mobile
<geri> thats why i sent the penti link
<sirppi> i see
<geri> i feel like an influencer xd
<beneroth> well mobile phones are universal computers crippled by vendors, so...
<beneroth> geri, haha :D
<sirppi> you are one, geri
<sirppi> yeah yeah
<beneroth> we didn't pay him!!
<sirppi> anyways what yall upto
<geri> doing my daily japanese practice
<abu[7]> Hi sirppi!
<sirppi> hello abu!
<sirppi> geri: you know japanese!! thats cool
<sirppi> ive heard that... in japanese a single glyph is a whole world
<sirppi> *word
<sirppi> effishiensiii
<geri> ใ„ใˆใ€ๅฐ‘ใ—ใ ใ‘ๅˆ†ใ‹ใ‚‹ใ€ใงใ‚‚ใ‚ขใƒ–ใใฎ่จ€่‘‰ใŒ้ŽๅŽปใซๅˆ†ใ‹ใ‚Šใพใ—ใŸ (very scuffed)
<geri> computer makes writing this possible
<sirppi> wow
<sirppi> translation?
<tankf33der> use chatgpt
<geri> "no, i only understand a bit, but in the past abu used to know it well"
<geri> got rusty though
<tankf33der> geri: chatgpt did not translate 'abu' word :)
<geri> on a 1/10 scale, how badly did i phrase it abu[7]
<geri> tankf33der: google translate didnt either
<abu[7]> 9 at least :)
<geri> a bit more and id get perfect badness score B)
<abu[7]> ใ‚ขใ should be ใ‚ขใƒ–
<beneroth> hey tankf33der :)
<tankf33der> o
<tankf33der> o/
<geri> its "abu sono kotoba"
<geri> s/"/"demo/
<abu[7]> these words
<abu[7]> Hi beneroth, tankf33der!
<geri> the party sure is active today
<beneroth> servus sensei
<abu[7]> I'm in a local train north of Hamburg, bad network
<geri> mr. burger being near hamburg sounds a tad comedic :D
<abu[7]> โ˜บ
<sirppi> sure it is
<sirppi> anyways i gotta go now, catch y'all later!! :))
sirppi has quit [Quit: Lost terminal]
<geri> that instant quit
<beneroth> probably reading the pil doc offline for less disturbance and faster reading?
<geri> possible
<beneroth> or hungry for burgers
<geri> very possible
<geri> for me dark reader messed with local copy of pico docs, makes me sad
<geri> cause white theme is hurtful for my eyes
<beneroth> you know CSS?
<beneroth> just change the doc :P
<abu[7]> */
<geri> yes, i couldnt debug it yet though
<geri> cause dark reader messes with css itself
<beneroth> then use (doc) or (help) in debug repl instead
<beneroth> or use w3m to read doc
<beneroth> dark reader sounds like bad software
<geri> modern web is bad software
<geri> make dark theme the default!!
<beneroth> T
<geri> i wonder if i can make pil open docs in eww in emacs
<geri> probably with some magic
<beneroth> magic is just programming that is not understood
<beneroth> I don't like magic
<geri> you sound like a cynical and disgruntled adult
<geri> magic is calling emacs client within emacs to open the browser in parent emacs
<geri> :)
<beneroth> xD
<beneroth> yo dawg I heard you like emacs
<geri> or finally figuring out how to make pile mode talk to emacs consistently
<geri> i wanted to do completion by reading outputs of (all) in emacs but it was like too big or something and everything broke
<beneroth> your own pil mode?
<geri> for emacs, yes
<geri> good indentation and some repl interop unlike what was there
<beneroth> I think there are like 4 pil modes
<beneroth> all suffering from lisp curse
<geri> i know with mine there are 3
<beneroth> I think 4 with yours xD but you might be right
<beneroth> no chance I can find them
<geri> plisp mode is broken as hell and one i got inspired by had broken indentation
<beneroth> I use the very old pil mode which was once part of the pil distro. but I basically just use it with paredit and work with a separate terminal otherwise
<geri> got a link to the ref in git repo where it was still present or smth?
<beneroth> uh, I must first find a picolisp github then...
<geri> i think it might be the same one that i was inspired by
<beneroth> it's certainly a bit buggy :)
<geri> want my indent function? it seems pretty good)
<geri> except i forgot smth and its garbage incarnate
<beneroth> smth?
<geri> s/i/if i/
<geri> smth == something
<geri> seems okay
<geri> pile-indent-line is what should be interesting for you
<geri> although itll be slightly buggy if you dont colorize strings and comments
<beneroth> I do
<beneroth> thanks
<geri> also if you like putting newlines in the middle of a function youll hate it
<geri> forgot to say
<geri> xd
<beneroth> damn
<beneroth> my precious newlines
<geri> just not in the middle of the function...
<geri> if you need it i can try to implement it some time later and send you updated version
<beneroth> what about high unicode codepoints? (de ๐Ÿ˜Š () (prinl "๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š"))
<geri> damn those use cases are insane
<geri> seems okay
<geri> you can actually call funcitons emojies
<geri> insanity
* beneroth just got the idea that corporate HTTPS MitM traffic analysis stuff might choke on smileys in URLs... to be tested...
<beneroth> geri hehehe :)
<beneroth> valid symbols
<geri> i shouldnt be surprised cause symbols and strings are the same thing
<geri> in here i mean
<beneroth> right in the spirit of https://www.rfc-editor.org/rfc/rfc5841.txt
<beneroth> geri, yep exactly
<beneroth> well to be precise
<beneroth> picolisp has no strings
<geri> lies
<beneroth> and I would say in picolisp strings are represented as symbols or list (of symbol elements)
<geri> check (doc 'str?)
<geri> B)
<beneroth> str? checks if its a symbol outside of the current intern tree
<beneroth> so gives T for namespaced symbols too
<geri> > Returns the argument any when it is a transient symbol (string), otherwise NIL.
<geri> (string!)
<geri> i like idea of not having special structures for strings, but it does sacrifice performance for orthogonality
<abu[7]> T
<geri> which usually doesnt mean shit - people write production systems in python
<geri> XD
<beneroth> well the global deduplication of strings saves again some memory and thus performance
<geri> some lisps intern strings too
<geri> s/some/some other/
<geri> honestly it sounds like people going "muh performance" live in a world where python is not a thing
<abu[7]> "muh"?
<geri> its like uh
<geri> half-crying version of "b-but my performance!"
<abu[7]> :)
<beneroth> but but but python is ruling the world!!11
<beneroth> glorious libraries (wrappers for C++) !
<beneroth> I think python is the new java :P
<geri> i dont hate python, but like there are languages other than C and that's okay xd
<abu[7]> right
<beneroth> T
<geri> beneroth: libs which you could get into picolisp i bet ;)
<beneroth> yeah
<geri> python is still better than java too, cause print("hello world") vs a full-blown class for a line of operations
<geri> apparently some new java version is gonna make it possible to write hello world in 1/few lines
<geri> too bad people wont get to use it cause enterprise
<beneroth> oh Java is re-inventing C++ now? :O
<geri> dunno about that
<beneroth> I mean because in C++ you could always write without OOP
<geri> ah
<geri> i think its only for main file
<geri> may be wrong tho
<bjorkintosh> I think python slithers around your throat and then proceeds to squeeze the hell out of you. it's a language as large, if not larger than C++
<beneroth> srsly?
<beneroth> I don't know python well
<beneroth> but C++ is a huge
<beneroth> a project is never really in C++, more like a C++ subset
<beneroth> what makes python large, if you leave the libs array? is it that big?
<geri> eh, you need relatively basic knowledge to use python, so i cant consider it "as large"
<geri> like, if you can ignore 90% of features while writing code just fine in my eyes its optional extensions and not language features xd
<bjorkintosh> beneroth: that's what's happening with python.
<bjorkintosh> it starts off really easy. but to become effective, you have to know a lot.
<bjorkintosh> there's a certain cohesiveness to lisp that is missing from languages like python and c++, so ultimately, that's what brought me back to the fold.
<bjorkintosh> as the language grows, it grows from within. as opposed to growing from some c library or something in a hodge podge fashion.
<geri> lisps mostly grow from the outside, no?
<geri> except cl is absolutely huge on its own
<bjorkintosh> geri: lisp begets more lisp, is what I mean.
<geri> like not more C core code?
<bjorkintosh> you want a new paradigm? right it in lisp.
<bjorkintosh> right. at least that's how the books make it look :-)
beneroth has quit [Ping timeout: 272 seconds]
<geri> i think that is how it is
beneroth has joined #picolisp
beneroth has quit [Client Quit]
beneroth has joined #picolisp
beneroth has left #picolisp [#picolisp]
beneroth has joined #picolisp
<beneroth> bjorkintosh, geri well lisp has small and consistent syntax. doesn't python too?
<bjorkintosh> beneroth: kinda.
<bjorkintosh> beneroth: this is half of what it takes to properly master the language: https://x.com/real_super_aj/status/1250741309129854976
<bjorkintosh> the other half is the beginner friendly books. and then you have the dialects built upon it: like scipy, pandas, numpy, and so on.
<bjorkintosh> there used to be one way to do things. this is no longer true.
<bjorkintosh> there are at least 10 ways ... and each time the language version changes, more ways are added.
<beneroth> puh. I'd think reading the python source might be less to read...
<geri> beneroth: not really xd
<geri> lisp and forth are the most minimal when it comes to syntax i think
<geri> personally im somewhat comfortable with python and i hadnt read a single book on it
<geri> i had a teacher help me a few times and thats about it
<bjorkintosh> APL too.
<geri> *how do you even type that*
<geri> (ik emacs can do it)
<beneroth> you buy the IBM typewriter, no? :P
<geri> xwx
<geri> C-x 8 RET lambda RET => ฮป
<geri> B)
<geri> still a pain
<geri> there was one like tex input mode
<beneroth> you know in the original lambda calculus, the usage of the greek lambda letter was not intended, it should have been a simple arrow sign to show where the replacement happened, but the typesetter made a lambda letter out if it
<geri> is that real
<geri> XD
<geri> did they call it lambda calculus after the fact
<beneroth> not sure. maybe.
<beneroth> I think they did
<geri> gonna be slow, gotta work for a bit
<beneroth> no work. learn useless facts now.
<beneroth> :P
<geri> yes work, cope with me not being there for an hour B)
<beneroth> good. happy working. I'll try the same. it's just too hot though...
<geri> i started a part time job and my brain just doesnt wanna work at all at weekends
<geri> not for this anyway, writing interpreters is fine XD
<bjorkintosh> they did.
<bjorkintosh> it was meant to be a hat.
<bjorkintosh> ^
<geri> i remember that lambda in haskell is backslash, there was a joke that if you squint hard enough it looks like a lambda
<beneroth> what are you supposed to work, geri ?
<geri> i missed the meaning of the message ๐Ÿคง
<geri> okay, worked my barely one hour
<geri> aint much but its honest work
<beneroth> well done
<abu[7]> ๐Ÿ‘
alexshendi has joined #picolisp
<beneroth> hey alexshendi
<alexshendi> hey beneroth, how is life these days....
<beneroth> alexshendi, too hot. otherwise good. for you?
<alexshendi> Also, good. But definitely too hot today.
<beneroth> nice to hear that live is good to you :)
<beneroth> abu[7], situation: we have a server running with a server socket, with a (task) set up to create a new task when a client connected. so now *Run has tasks for the server socket and maybe multiple client connections. Question: I assume when a client connection is closed without TCP closing, then the client connection fd remains indefinitely in *Run, correct? how to prevent having too many client connections open? install a timer task going through
<beneroth> client connection fd's and closing them after a while?
beneroth has quit [Ping timeout: 264 seconds]
beneroth has joined #picolisp
alexshe38 has joined #picolisp
alexshendi has quit [Read error: Connection reset by peer]
switchy has quit [Ping timeout: 276 seconds]
beneroth_ has joined #picolisp
beneroth has quit [Ping timeout: 258 seconds]
switchy has joined #picolisp