AngryBeaner8 has quit [Remote host closed the connection]
<cobax>
the folks at #chicken were praising picolisp today
aw- has quit [Quit: Leaving.]
<cobax>
ok, I'm new when it comes to programming with dynamic bindings. after reading through the Picolisp docs for a few days it seems there are no serious downsides to dynamic bindings. I remember reading a lot of FUD about it
Skainet has joined #picolisp
Skainet has quit [Remote host closed the connection]
Archwyrm15 has joined #picolisp
Archwyrm15 has quit [Remote host closed the connection]
buckley31023 has joined #picolisp
buckley31023 has quit [Remote host closed the connection]
<beneroth>
Hi cobax, aw-, Regenaxer, Nistur ~(rest)
<Regenaxer>
Hi beneroth + Nistur
<beneroth>
cobax, I had not to learn any rules or habits to program safely with dynamic bindings, I think. It does not really require any consciousness effort.
<Nistur>
o7
<beneroth>
you don't have to pass big argument lists nor structs/objects (as parameter container), you can just relate to variables in higher levels, that is pretty handy (in picolisp those are called inline functions, prefixed with underscore _)
<beneroth>
very handy when this mechanism can be used. actually in most cases not necessary.
<beneroth>
the other thing it relates to is the implementation of FEXPRs (used for similar things as macros in other languages, but more powerful), very handy to implement a DSL (e.g. @lib/xhtm.l). this is a bit tricky but there a good examples to learn from.
alexshendi has quit [Read error: Connection reset by peer]
<freemint>
good morning
<freemint>
I got some questions how to 'match properly
<freemint>
is there away to scope the binding locally when you do not what patters are being matched against
friden29 has quit [Remote host closed the connection]
orivej has quit [Ping timeout: 252 seconds]
<beneroth>
freemint, let and use
<beneroth>
wait, I have to read the question properly
Tornevall11 has joined #picolisp
Tornevall11 has quit [Remote host closed the connection]
<freemint>
beneroth i get a "unknown" list with patterns and match against it. I want to know whether these is a way to "contain" pattern bindings locally without having to parse the list of patterns
pierpal has quit [Ping timeout: 272 seconds]
razzy has joined #picolisp
<beneroth>
(match (1 @d 4 5) (1 4 4 5)) -> binds a list to @d
<beneroth>
fill just replaces the symbol with its value, so (1 (4) 4 5) is correct
<beneroth>
a @symbol within a pattern list in (match) binds one or multiple list elements to that @symbol. so its always a list
<freemint>
Regenaxer the write byte to memory will be really helpful
<freemint>
This way i can write RAM for my virtual CPU (if i want to push my disassembler a little) with ease
<Regenaxer>
Where do you need it?
<Regenaxer>
ok
<beneroth>
it was also used in the infamous 4gen languages, := for assignment and = for comparison. 4gen langs were when some believed we just have to use plain english words instead of special letters in our programming languages and then non-programmers (the guys with the business knowledge) are able to program. turned out wrong.
<freemint>
Byte addressable is perfect for that
<alexshendi>
beneroth : that pages says it's postfix.
* alexshendi
has one of those.
<beneroth>
"Polish notation, usually in postfix form," T
<beneroth>
the one I saw in use where prefix, I'm pretty sure
<beneroth>
s/where/was
<beneroth>
my english module is failing
<Regenaxer>
I still have a HP 29 C, but it does not run any more
<Regenaxer>
RPN = reverse polish notation
<Regenaxer>
postfix
<freemint>
Regenaxer i kinda find the thought scary to implement a CPU in PicoLisp let's see if i can get that far
<freemint>
Also: What would you say if Linux would boot on it?
<freemint>
booting Linux in PicoLisp ;)
<Regenaxer>
Wow, big task!
<freemint>
(running PicoLisp?)
<aw->
freemint: i've implemented a CPU in PicoLisp, you can do it
<freemint>
aw- can it run Linux?
<aw->
no
<aw->
it's 8bits
<aw->
lol
<freemint>
Ok
<aw->
freemint: is this a school project? or personal?
<beneroth>
"Basically indexOf() is a method belongs to string(array object also), But while calling the function you are passing a number, try to cast it to a string"
<Regenaxer>
I found this bug now despite it is there all the time
<beneroth>
good
<Regenaxer>
occurs only if more than one form is on the page, and the second one has a checkbox at the same position as another field in the first form ;)
orivej has quit [Ping timeout: 240 seconds]
<beneroth>
uh
<beneroth>
name clash?
<Regenaxer>
yeah
freemint has joined #picolisp
<Regenaxer>
The component names are generated
<beneroth>
maybe there is a way to improve the generator
<Regenaxer>
I think not, cause the GUI operates on the global *Gui variable
<Regenaxer>
so the names are "*Gui:1", "*Gui:2" etc in each form
<Regenaxer>
Normally no problem, as JS does not use the names
freeemint has joined #picolisp
<Regenaxer>
*only* in checkboxes
<Regenaxer>
So now I simply do
<Regenaxer>
for (var i = 1; i < lst.length; ++i) │···············
<Regenaxer>
if (lst[i] == fld) │···············
<Regenaxer>
lst[i - 1] = val;
<Regenaxer>
instead of the (wrong) document.getElementsByName(fld.name)[0].value = val
<Regenaxer>
ie the [0] is wrong
<Regenaxer>
I have to find the field, and then take the one *before* that
<Regenaxer>
Never mind, now it should work
freemint has quit [Ping timeout: 240 seconds]
tomato13 has joined #picolisp
<Regenaxer>
Hmm, however, syntax error
<Regenaxer>
semicolon missing?
<Regenaxer>
ok, found
<Regenaxer>
Already too late today ;)
tomato13 has quit [Remote host closed the connection]
<beneroth>
js is mess.
<Regenaxer>
indeed
freemint has joined #picolisp
freeemint has quit [Ping timeout: 252 seconds]
freemint has quit [Ping timeout: 245 seconds]
freemint has joined #picolisp
freeemint has joined #picolisp
freemint has quit [Ping timeout: 252 seconds]
freeemint has quit [Ping timeout: 240 seconds]
freeemint has joined #picolisp
freeemint_ has joined #picolisp
freeemint has quit [Ping timeout: 252 seconds]
freeemint_ has quit [Ping timeout: 245 seconds]
orivej has joined #picolisp
freemint has joined #picolisp
yogako20 has joined #picolisp
yogako20 has quit [Remote host closed the connection]
freeemint has joined #picolisp
freemint has quit [Ping timeout: 252 seconds]
freeemint has quit [Ping timeout: 252 seconds]
dwts12 has joined #picolisp
freemint has joined #picolisp
freeemint has joined #picolisp
dwts12 has quit [Ping timeout: 246 seconds]
freeemint_ has joined #picolisp
freemint has quit [Ping timeout: 260 seconds]
freeemint has quit [Ping timeout: 252 seconds]
freeemint_ has quit [Ping timeout: 252 seconds]
freemint has joined #picolisp
orivej has quit [Ping timeout: 260 seconds]
viaken has quit [Quit: reboot]
viaken has joined #picolisp
<cobax>
beneroth: hi beneroth, and thank you, I had not run across "inline functions" prefixed with underscore yet, I'll look for them now.
<cobax>
beneroth: I also think your characterization of 4gl is focused on just one detail and hence wrong because of its being too narrow.
<cobax>
nothing beats 4gl when it comes to having an integrated environment for rapid application development, hence why 4gl companies are millionaire companies
<cobax>
beneroth: I'm not sure I understand how someone like you who understands the mess that is web dev and is a picolisp programmer still believes those often repeated tales of 4gl failures.
<cobax>
most mission-critical environments I can think of use 4gl successfully (circuit design, industrial robotics, hospital software, shipping container software)...
<cobax>
And thinking non-programmers can code in simplified environments is an error that not just 4gl suffered in the past but technologies today suffer from as well
libertas has quit [Ping timeout: 240 seconds]
libertas has joined #picolisp
libertas has quit [Ping timeout: 260 seconds]
<beneroth>
I worked many years with 4gl system Navision
<beneroth>
with wrong I meant the hypothesis that it's more efficient to let non-programmers program
<beneroth>
I totally agree with you that they are often very nice integrated systems.
<beneroth>
sorry if I didn't explained my point better, thanks cobax :)
libertas has joined #picolisp
<cobax>
beneroth: ah ok, I just wanted to make sure I was not missing anything... y'know, in case there is a better idea than 4gl :)
<beneroth>
afaik 4gl is also a set of languages from a certain timespan, no?
<beneroth>
I saw a presentation from Alan Kay (on video). I try to find it again... I can't recall the name of the system (CS work) he showed
<beneroth>
interactive programming, mostly visual, but not the native visual programming à la UML etc
<beneroth>
still searching, but ha this Alan Kay line is golden, especially in picolisp context
<beneroth>
Alan Kay: "I'm not against types, but I don't know of any type systems that aren't a complete pain, so I still like dynamic typing."
Tene0 has joined #picolisp
<beneroth>
ah agree, based on my personal experience.
<cobax>
beneroth: I think 4gl definitely is a set of languages from a certain timespan, but also that that fact robs us of good terminology
<cobax>
because if that is all 4gl is then now I don't have a term to describe integrated programming systems
<beneroth>
wikipedia states
<beneroth>
While the definition of 4GL has changed over time, it can be typified by operating more with large collections of information at once rather than focusing on just bits and bytes. Languages claimed to be 4GL may include support for database management, report generation, mathematical optimization, GUI development, or web development. Some researchers state that 4GLs are a subset of domain-specific languages.
<beneroth>
so picolisp with pilDB and form.l falls into 4gl :)
<beneroth>
I need to go
<beneroth>
just write more, if you like
<beneroth>
bbl
<beneroth>
btw. c++, python, java, etc fall all unter 3gl
<beneroth>
thats not disputed
krav_29 has joined #picolisp
<cobax>
beneroth: I would agree with that. I would also agree with this excerpt from c2 wiki:
<cobax>
"4GL began as a technical term but was emptied of all meaning by marketroids back in the 1980s, so it currently tends to be considered to be marketing fluff unless proven otherwise"
<cobax>
beneroth: even all the web frameworks du jour fall under 3gl
<cobax>
we agree there
<cobax>
beneroth: I actually would call MUMPS 4gl and it's from 1966 well before that term came into existence
<cobax>
I would also say dBase is 4gl and I don't usually see dBase in 4gl lists including the wikipedia list unless I missed it
Tene0 has quit [Ping timeout: 252 seconds]
<cobax>
as a matter of fact I have discovered picolisp while looking for a 4gl solution to the web
krav_29 has quit [Ping timeout: 245 seconds]
<cobax>
had I not found picolisp I would probably have settled for Seaside
<cobax>
aw-: it is also interesting that other dynamic lisps seem to have found different solutions for the so-called "dangers" of dynamic binding < sis mom