ChanServ changed the topic of #picolisp to: PicoLisp language | Channel Log: https://irclog.whitequark.org/picolisp/ | Picolisp latest found at http://www.software-lab.de/down.html | check also http://www.picolisp.com for more information
styx has joined #picolisp
karswell_ has quit [Read error: Connection reset by peer]
styx has quit [Client Quit]
reed has quit [Quit: Page closed]
<yunfan> what do you think about https://github.com/eudoxia0/interim
<tankf33der> yunfan: known, nothing special
<yunfan> tankf33der: why?
<tankf33der> all this is waste of time, feel bad
<tankf33der> my zero rule: only coding matters.
<tankf33der> choose any language and just coding
<tankf33der> reading about interim is useless, coding on interim is very cool
<aw-> ?
<Regenaxer> Interim seems the exact opposite of PicoLisp
<Regenaxer> Static, no garbage collection
<yunfan> Regenaxer: so if i use both langs, it will be a taiji of lisp :D
<Regenaxer> yunfan: a taiji?
<yunfan> hope you love the symbol ;]
<Regenaxer> oh, I see :)
<Regenaxer> hmm, so you get a taiji if you throw together opposing things?
<Regenaxer> "absolute and infinite potential" is in PicoLisp alone ;)
<yunfan> yes
<yunfan> that's the core concept
<yunfan> at least from my viewpoint
<Regenaxer> No need to fuzz around with explicit (allocate ..)
mtsd has joined #picolisp
mtsd has quit [Read error: Connection reset by peer]
mtsd has joined #picolisp
<beneroth> yunfan, you know http://picolisp.com/tractatus/ ? :)
<beneroth> Haven't heard of interim, thanks for the link! :)
<yunfan> beneroth: i dont know that before
<yunfan> beneroth: do you use any rss reader?
<beneroth> it's a good overview on the core concepts in picolisp, written by Regenaxer
<beneroth> no. Never did. I most likely should, can you recommend one? Currently I operate on opening way to many browser tabs
<yunfan> i use inoreader currently
<yunfan> but i am planning to build my own for better experiences
mtsd has quit [Remote host closed the connection]
<beneroth> good plan, I would be interested :)
mtsd has joined #picolisp
<aw-> hi all
<aw-> is there an RSS feed generator in picolisp?
<aw-> maybe using (xml) ?
<Regenaxer> Not that I know of
<Regenaxer> Long time ago Henrik Sarvell had an RSS reader in pil
<Regenaxer> Don't know the state now
<aw-> writer, not reader?
<Regenaxer> Not sure
<aw-> hmm
<Regenaxer> Great! Good idea
mtsd has quit [Remote host closed the connection]
<aw-> Pilog should probably have its own page as well
mtsd has joined #picolisp
<Regenaxer> I don't think so. It is too deeply dependent on PicoLisp
<aw-> oh i see
<aw-> or perhaps add more info about it on the PicoLisp wikipedia page
<Regenaxer> yeah, better there I think
alexshendi has joined #picolisp
mtsd has quit [Remote host closed the connection]
mtsd has joined #picolisp
mtsd has quit [Read error: Connection reset by peer]
mtsd has joined #picolisp
mtsd has quit [Read error: Connection reset by peer]
mtsd has joined #picolisp
mtsd has quit [Read error: Connection reset by peer]
<tankf33der> Regenaxer: here ?
<tankf33der> how to implement (% -123 45)
<tankf33der> ?
<tankf33der> ha, found
<tankf33der> already implemented.
<tankf33der> :)
<Regenaxer> ok :)
<Regenaxer> I'm never sure about the sign
<Regenaxer> There is a difference between modulus and remainder, but I don't remember which was which for negative numbers
<aw-> PAIP chapter on logic programming / Prolog here: https://git.io/vhUS3
<Regenaxer> yeah, cool book
<tankf33der> next task:
orivej has quit [Ping timeout: 248 seconds]
<beneroth> good mail on ML, Regenaxer
<Regenaxer> Hmm, I feel it rather confuses even more ;)
<beneroth> I meant your response to Arie
<beneroth> explaining the basic misconceptions :)
<Regenaxer> yes
<Regenaxer> But it is hard to explain, all the confusion about quotes and (non)evaluating
<Regenaxer> I'm not even sure what exactly he wanted to do
<beneroth> I guess he just wanted to assign a variable.
<beneroth> I found your email spot-on, would have written it the same way.
<Regenaxer> yeah, but he was content in the end with (de x . '(1 2 3 4))
<Regenaxer> ok, thanks!
<beneroth> well it was the first way which worked for him, but he surely hasn't grokked it. You explained the background and alternatives.
<beneroth> I would guess most people have to play around a bit and fall into the numerous traps before grokking the underlying architecture and concepts :)
<Regenaxer> He seemed to have some knowledge about Scheme I think
<Regenaxer> 'set!' may be in Scheme, not sure
<beneroth> Of course some people could get there faster by reading and learning the picolisp internal structures first, but I guess many/most people come there with a more hands-on approach ;-)
<beneroth> yeah
<Regenaxer> yes, and most give up quickly :)
<beneroth> T
<Regenaxer> understandable
<beneroth> but that is a widespread problem, not limited to programming I would say. :P
<Regenaxer> true
<Regenaxer> Must go, bbl
<Regenaxer> afp
<beneroth> cu!
<tankf33der> beneroth: picolisp shipped with setf function
<tankf33der> hidden in misc
<rick42> sup. how ru, beneroth, Regenaxer and tankf33der?
<rick42> diff between de and def is only to be understood be reading ref
<rick42> imho
<beneroth> T. but maybe not on the first reading ;)
<rick42> hehe
<beneroth> sup rick42 o/ nice to see you here :)
<rick42> \o likewise
<beneroth> tankf33der, oh nice find!
<rick42> tankf33der's gone deep already
<rick42> mmans repo. he's still keeping it up? nice.
<beneroth> it's automatically kept up to date (scrapping Regenaxers download page) afaik
<rick42> even better!
<beneroth> common, we're picolispers ;)
<tankf33der> beneroth: good arie didnt find it
<beneroth> haha, maybe. maybe it would speed up his confusion and than his understanding. dunno :)
<beneroth> it has a nice Regenaxer comment at the top :D
<rick42> :) (just read it)
<rick42> my favorite part is the let block that contains the expression (eval "P"). very nice example of expert lisp programming (and leveraging dynamic binding)
<beneroth> yeah I saw the file ages ago, forgot it.
<beneroth> haha, yeah I have such stuff in my code, too. works well. but its not optimal.
<beneroth> I'm working on better solutions.
<rick42> (I'm singing "Don't Fear Dynamic" to the tune of "Don't Fear the Reaper" by BOC lol :)
<beneroth> I fear I have a lot of ugly picolisp code currently in my software. It's a work in progress, and good enough for my current (and past) applications. One reason why I don't publish my code yet.
<beneroth> haha :)
<rick42> you are a perfectionist, like me :)
<beneroth> T
<beneroth> One need to be careful with perfectionism. Too often people use it as an excuse to do nothing at all.
<beneroth> One must not be afraid of failure. Failure is progress.
<beneroth> Well, knowledge-gaining, to be more accurate.
<beneroth> Edison "I didn't had 500 failures. I found 500 ways which don't work."
<rick42> lol
<rick42> T
<rick42> on the subject of `setf` in picolisp: aah, might as well use the intrinsic `set`. n00b's have to learn right away that picolisp is a differnet lang from CL, scheme, etc. Don't let the similar syntax fool you -- it's a diff lang with diff assumptions, ideas, etc -- just hunker down and learn it.
<rick42> it's difficult for opinionated people (like me, I'm the perfect example) to approach a lang like picolisp, after carrying around the ideas of other lisps, as if there were no other ways of doing things (like binding, symbols, etc). To learn picolisp, people like me need to dump the baggage carried from our previous experiences (no matter how important we believe thay are) and give picolisp an honest consideration. I
<rick42> ly.
<rick42> think this is haaaaard. It's hard to think about things without the context that you are used to carrying around (because, after all, that context has *helped* you in the past to understand things in an organized way, right?). Well, we don't have to ultimately forget the past (we shouldn't), but learning new things with a truly fresh (not empty) mind is what's need, but I have found this very challenging, personal
<rick42> bbl
<beneroth> T
styx has joined #picolisp
<Regenaxer> ret
<Regenaxer> Hi rick42! :)
<Regenaxer> Yeah, 'setf' was meant as a joke ;)
reed has joined #picolisp
<reed> Hi all. Is there a way to open a file that doesn't exist yet with the "vi" command?
<reed> If I could do this simply, I could almost completely avoid leaving the pil repl .
<beneroth> yeah I see your point. Had this thoughts too, at the beginning.
<beneroth> :)
<beneroth> afaik.. no. because (vi) does not take a file
<beneroth> but you can surely make it happen
<beneroth> maybe (call 'vim "path/to/new/file") and then (load "path/to/new/file") =
<beneroth> ?
<beneroth> you could put it into a single function
<reed> hmm, let me try
<reed> (de vi-open (Filename) (call 'vim Filename)) works well
<reed> Is there a way to load that function in the repl without modifying my "@lib/lib.l" file?
<reed> And of course without loading it manually every time
<beneroth> (load Filename) ?
<beneroth> then henceforth working with (vi) instead of (vi-open). (vi-open) only to create new functions
<reed> I mean, to have the "vi-open" function available by default.
<reed> Is there like a .pil config file?
<beneroth> there is a .pil directory in your home dir
<beneroth> containing the repl history (when pil started with + debug flag)
<beneroth> and a directory tmp, there (tmp) creates files (and deletes them automatically when the process ends normally)
<beneroth> pil itself is a simple bash script
<beneroth> you could customize the pil bash script or make your own separate version
<beneroth> it basically starts the picolisp binary and loads some (usually essential) picolisp standard "libraries"
<reed> Ahh, that seems reasonable. Thank you!
<beneroth> glad to help :)
<reed> So, adding the definition to the "editor" file in the .pil directory worked, and seems a little cleaner than changing the script in /usr/bin
<beneroth> perfect :D
<Regenaxer> hi reed, this is possible
<Regenaxer> At least with Vip which is what I'm using
<reed> Is there a more standard way than defining a wrapper function in the "editor" file?
<Regenaxer> If you include "@lib/vip.l" on your command line
<Regenaxer> no need for a wrapper
<Regenaxer> Just (vi "myfile")
<Regenaxer> or (vi 'car) to edit sources as before
<reed> when I do that on an empty file, I get an error "/usr/lib/x86_64-linux-gnu/libncurses.so: file too short"
<Regenaxer> ah
<Regenaxer> yeah, the ncurses problem
<Regenaxer> I described it in the Vip article, let me check
<Regenaxer> $ sudo apt-get install libncurses5
<Regenaxer> $ (cd /lib/x86_64-linux-gnu; sudo ln -s libncursesw.so.5.9 libncurses.so)
<beneroth> oh (vi) takes a filename argument? didn't know. sorry, reed. I'm should update :)
<Regenaxer> beneroth, but only the Vip version
<beneroth> away a while (getting some outside air)
<Regenaxer> not the default 'vi'
<beneroth> Regenaxer, ok, I guessed so
<Regenaxer> cu beneroth!
<beneroth> important distinction, ok
<beneroth> cu!
<Regenaxer> reed, indeed, this ncurses problem is nasty
<reed> Ahh, I see. I think I'll stick with the "editor" file hack.
<Regenaxer> ok
<Regenaxer> I don't know how this ncurses problem can be solved cleanly
<Regenaxer> the .so file is not a lib but contains text: INPUT(libncurses.so.6 -ltinfo)
<Regenaxer> So a kind of library redirection?
grp has joined #picolisp
<Regenaxer> hmm, I see. It is a feature of the GNU linker ld. A "linker script"
<Regenaxer> 'native' does not handle this
<Regenaxer> A bug in 'native'?
<rick42> Regenaxer: hi! and lol, yes, it was a good joke :)
<Regenaxer> :)
<Regenaxer> This gnu system of "linker scripts" is just stupid
<Regenaxer> It makes it impossible to dlopen() a .so file :(
<Regenaxer> I really don't find a way to handle this in a clean way
<Regenaxer> (except from manually setting a symbolic link as above, which is it good)
<tankf33der> after signify i can implement password manager in picolisp
<tankf33der> hm
<Regenaxer> Hmm, I change @lib/vip.l to call "libncursesw.so.6" directly
<Regenaxer> Then the symbolic link is not needed
<Regenaxer> May break on some systems perhaps which do not have "libncursesw.so.6" yet
<Regenaxer> But on Termux I don't have "libncursesw.so.5"
<freemint> oww that sucks
<Regenaxer> yep
<Regenaxer> On my remote servers I don't have "libncursesw.so.6"
<Regenaxer> What is the best way?
<Regenaxer> grr, on all Debian systems only 5 is available
<Regenaxer> but on Termux only 6
<Regenaxer> I give up
<Regenaxer> Works for me
<beneroth> tankf33der, yay a pw manager would be nice
<beneroth> I would use it
<Regenaxer> Hehe, I use Vip for that too
<Regenaxer> It uses ccrypt internally, via the :key command
<Regenaxer> (one more of the advantages over Vim for my use cases)
<beneroth> you write emails with vip too?
<beneroth> :P
<Regenaxer> Sometimes
<Regenaxer> But for reading mail I still use Vim
<Regenaxer> cause Vip handles only utf8
<Regenaxer> Everything else is Vip. I have a symlink vi -> ~/bin/vip
<beneroth> :)
<Regenaxer> Vip also handles stdin, so it is also my pager for 'man'
<Regenaxer> or shell pipes
<Regenaxer> For pil it is best of course (comments, indentation, super parentheses etc.)
<Regenaxer> Another thing which I disliked in Vim is that it has no useful return code
<Regenaxer> vim xxx &&& doSomething
<Regenaxer> Vip returns true for :x and false for :q
<Regenaxer> so the above works
<beneroth> lol
<Regenaxer> Vip also knows about namespaces
<Regenaxer> Another stupid thing in Vim is that the command window itself is *not* editable with VI style. Ridiculous!
<beneroth> can I found out how to integrate Vip with html textarea by looking into pilBox ?
<Regenaxer> PilBox does not use Vip
<beneroth> oh okay
<Regenaxer> There are no ncurses
<beneroth> ah makes sense
<Regenaxer> The REPL uses a browser textarea
<Regenaxer> no good editing :(
<beneroth> T
<beneroth> I envision a html vip with paredit
<Regenaxer> Never thought in that direction
<beneroth> sounds like a plan. though sounds like re-implementing (html instead of ncurses)
<Regenaxer> 20 years ago there was Elvis
<beneroth> different use cases I would think :)
<beneroth> elvis?
<Regenaxer> a VI clone with html editing
<beneroth> ah
<Regenaxer> also on Windows
<beneroth> afk, I need a shower & barbecue :)
<Regenaxer> Great! Have fun!
<beneroth> Thanks! You too! :)
<Regenaxer> :)
alexshendi has quit [Ping timeout: 240 seconds]
styx has quit [Quit: styx]
<freemint> good night
<freemint> i will be celibrating my birthday this weekend.
<beneroth> yay! Big party? or some relaxed comfortable time for you?
freemint has quit [Ping timeout: 260 seconds]
alexshendi has joined #picolisp
grp has quit [Quit: box shutting down...]
reed has quit [Quit: Page closed]
alexshendi has quit [Ping timeout: 256 seconds]