00:00:00 --- log: started forth/16.11.10 00:13:30 --- quit: nighty (Ping timeout: 250 seconds) 01:14:45 thanks 01:15:34 I'm curious, because of some of "John"'s messages, was there any Forth/-like with "Objects" on stack? 01:25:50 --- quit: M-jimt (Ping timeout: 245 seconds) 01:35:09 --- join: dys` (~dys@2003:5b:203b:100:6af7:28ff:fe06:801) joined #forth 02:23:13 --- quit: mnemnia (Remote host closed the connection) 02:23:23 --- join: M-jimt (jimtmatrix@gateway/shell/matrix.org/x-plaqafeekbyhketv) joined #forth 02:30:37 --- join: true-grue (~true-grue@176.14.222.10) joined #forth 03:34:09 --- join: Uniju (~frog_styl@cpe-74-78-4-232.mass.res.rr.com) joined #forth 03:36:02 --- join: mnemnion (~mnemnion@2601:643:8102:7c95:b082:1ddc:3f37:513d) joined #forth 03:40:15 --- quit: mnemnion (Ping timeout: 258 seconds) 04:08:49 --- join: nighty (~nighty@sp1-79-81-130.msb.spmode.ne.jp) joined #forth 04:16:29 --- quit: dograt (Quit: No Ping reply in 180 seconds.) 04:17:38 --- join: dograt (~dograt@unaffiliated/dograt) joined #forth 04:37:57 --- join: John[Lisbeth] (~user@52.165.40.155) joined #forth 04:38:04 I rewrote my javascript forth 04:38:46 now it's quote unquote stateless and it was alot easier to program that way 04:39:21 functions just accept stacks and return stacks 04:40:37 it's 81 lines right now but I haven't factored any of my code 04:41:36 it works on words except for ["this javascript array", 2] will be one word 04:42:22 "this is also one word" 04:42:47 { key: "this is also one word } 04:49:43 @John[Lisbeth] Is it up on Github? 04:50:10 my old version is 04:50:15 posthyperstruct.js 04:51:05 I could probably publish y new version now it runs stable-ly but I haven't implemented the parser completely yet and I wanted to finish the parser for this week's commit 05:18:34 there here's my 0.0.2 https://github.com/johmorrisbeck/posthyperstruct/blob/master/posthyperstruct0.0.2.js 05:41:22 --- join: groovy2shoes (~groovy2sh@unaffiliated/groovebot) joined #forth 05:49:57 function push(array, value){array.push(value); return array} 05:49:58 function swap(array){return push(push(drop(drop(array)), pop(array)), pop(drop(array)))} 05:49:59 wow 05:59:05 ? 06:08:17 what is wow? 06:08:19 is wow good? 06:09:30 Definitely not :) 06:09:52 lol 06:10:01 I'd say that is a decent swap 06:10:19 it gets the job done 06:10:35 right now it's still in javascript. I haven't finished the parser 06:13:37 I just wrote it that way so I could use a notation similar to polish notation 06:13:46 because javascript can kinda sorta do polish 06:14:07 What I think is going to be inefficient is passing around all of those arrays 06:14:12 sorry, how it is sorta polish ? 06:14:37 Well I mean if you just pretend the lefthand parentheses is on the left side of the word then it feels alot like lisp 06:14:56 function( argument) vs (function argument) 06:15:48 it's polish enough that it is easy for me to make some of these oneliners 06:16:01 whenever I have to recurse I first design the function with recursion then redesign it to use a loop 06:17:33 I may rework this logic so there is a local stack within main that gets operated on rather than passing around stacks because I can see that as a huge power waster 06:18:49 The trick is to first design it using function application so that you take a stack and return a stack, and then you redsign the program so that reads a variable in main and writes back to a variable in main 06:21:18 I also hope to be able to redefine my environmnet while it is running once my repl is going with some kind of javascriptEval word 06:27:08 why you don't make "global" array variable, but I'm zero level at JS ) 06:29:52 --- join: Zarutian (~zarutian@168-110-22-46.fiber.hringdu.is) joined #forth 06:31:05 --- quit: Zarutian (Read error: Connection reset by peer) 06:31:08 --- join: Zarutian_ (~zarutian@168-110-22-46.fiber.hringdu.is) joined #forth 06:47:25 the scoping in javascript is not really done well 06:47:35 and so to secure your things you need to put it in local or protect it some other way 06:47:39 so main is "global" 06:49:43 Like I said I may rework my code so there is an actual stack rather than stacks being pased around 06:50:25 cause I expect people to fill these things with huge databases worth of garbage 06:50:32 and I can't have it break or cause a leak 06:52:55 the issue is that I need to find a way to have the stack be local and protected and yet have it be shared by all of the core functions that operate on it 06:53:29 and of course I am going for minimalism as I go, syntactically and computationally 07:02:39 John[Lisbeth]: can you explain for me how you see scoping in Javascript done? 07:06:48 hold on let me just google it so I am being accurate 07:10:20 If I am to believe w3schools what I was referring to was in fact that I needed to use the var keyword when declaring variables in local scope 07:15:49 well, you need to use the var keyword for declaring variables. The global crap is indeed that. However you can assign or reference variables declared in an function inside another function inside the first one. 07:16:51 (Confusing way to explain lexical scoping) 07:25:44 my main worry is if people actually start coding in this thing because it is not secure 07:33:57 John[Lisbeth]: what is not secure and in what way? 07:34:10 It is not secure in the sense that I have not tested it for security 07:34:17 and as it stands untested it is more likely than not unsecure 07:38:18 how do you test it for security? 07:40:56 you google how to test for security and follow the advice within 07:42:38 --- join: rgrinberg (~rgrinberg@24-246-56-85.cable.teksavvy.com) joined #forth 07:53:28 --- join: ASau (~user@netbsd/developers/asau) joined #forth 08:15:47 John[Lisbeth]: most of those results are blatantly trollish 08:21:47 meh I figure I can sift through the bullshit 08:28:34 --- join: neceve (~ncv@unaffiliated/neceve) joined #forth 08:33:50 --- join: mnemnion (~mnemnion@2601:643:8102:7c95:b082:1ddc:3f37:513d) joined #forth 08:37:56 --- quit: mnemnion (Ping timeout: 245 seconds) 08:48:22 --- nick: Zarutian_ -> Zarutian 08:54:20 --- join: mnemnion (~mnemnion@2601:643:8102:7c95:b082:1ddc:3f37:513d) joined #forth 09:04:21 --- join: ASau` (~user@89.204.138.162) joined #forth 09:04:42 --- quit: ASau (Ping timeout: 260 seconds) 09:18:46 --- join: karswell` (~user@238.207.208.46.dyn.plus.net) joined #forth 09:21:04 --- quit: X-Scale (Ping timeout: 250 seconds) 09:30:57 --- join: lgstate (46abe34e@gateway/web/freenode/ip.70.171.227.78) joined #forth 09:31:28 this might sounds trollish, but is a geniune question: 09:31:53 I recently switched form Haskell to Clojure, and find Clojure a bit verbose (due to variable names -- and Haskell's point free style) 09:32:04 so I started reading up on point free style ... and ended up looking at joy / factor / forth 09:32:23 so it appears that forth is very popular in embedded devices / low level, but not as popular in things like javascript / web frameworks 09:32:41 is there a place I can read a good analysis on this? (the best I found was scheme vs forth on c2, which was not all that informative) 09:33:02 this whole notion of 'building language up' -- and also 'no variable names ==> shorter / more refactored functions" seems very interesting 09:34:10 --- quit: dys` (Ping timeout: 260 seconds) 09:39:21 lgstate, interesting question 09:39:51 Forth is very different from Joy and its derivatives. 09:40:55 And I think you've missed the whole class of interesting PLs. Just because of modern "pointfree" jargon. 09:41:33 http://evincarofautumn.blogspot.com/2012/02/why-concatenative-programming-matters.html 09:41:50 lgstate, There is an old classic terminology: function-level programming and combinator /vector languages. 09:43:26 So, my advice is to forget for a while about the trendy words like "concatenative" and "pointfree". 09:44:10 You may start with reading of classic Backus Turing award lecture. 09:45:32 WebAssembly will mean you can use Forth for web development without penalties. Brad Nelson is on Google's WebAssembly team and is doing Forth in WebAssembly. 09:47:48 lgstate, Speaking of modern function-level PLs, you may found Faust interesting: http://faust.grame.fr/ 10:04:46 --- quit: mnemnion (Remote host closed the connection) 10:06:50 --- quit: ASau` (Remote host closed the connection) 10:07:16 --- join: ASau` (~user@89.204.138.162) joined #forth 10:11:46 true-grue; hmm, so backus turing 'FP" is not scheme/haskell ? 10:11:57 I read it once, but I must have missed it's point if that's what you're saying 10:12:10 I thought the point was (1) don't use fortran, (2) don't use side effects, (3) compute instead of overwrite memory locations 10:13:36 lgstate, Sure, it's something different. In his lecture he compared lambda-based and combinator-based styles. And nowadays you can see the declaration that lambda calculus is the only basis for functional programming. 10:16:05 lgstate, One of his points is that you need to have algebraic rules for effective program transformations. And it's much easier to work with "algebra of programs" if you will get rid from the variables. 10:16:14 --- join: ASau`` (~user@89.15.237.20) joined #forth 10:18:00 --- quit: ASau` (Ping timeout: 256 seconds) 10:24:04 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 10:25:07 --- join: mnemnia (~mnemnion@152.179.131.166) joined #forth 10:27:55 --- quit: mnemnia (Remote host closed the connection) 10:28:08 --- join: mnemnia (~mnemnion@152.179.131.166) joined #forth 10:28:42 --- quit: mnemnion (Ping timeout: 260 seconds) 10:33:59 --- quit: mnemnia (Remote host closed the connection) 10:35:32 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 10:36:40 --- quit: mnemnion (Remote host closed the connection) 10:36:53 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 10:37:01 lgstate, https://en.wikipedia.org/wiki/Function-level_programming#Contrast_to_functional_programming 10:48:54 --- quit: mnemnion (Remote host closed the connection) 10:57:04 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 10:59:07 --- quit: mnemnion (Remote host closed the connection) 11:01:50 --- nick: karswell` -> karswell 11:12:19 --- quit: ASau`` (Remote host closed the connection) 11:12:37 --- join: ASau`` (~user@89.15.237.20) joined #forth 11:13:07 @pointfree Is he the guy who wrote Ricardo Forth? (No, I am not the author incase anyone was wondering) 11:13:25 Really interested to see what folks do with FORTH when WASM reaches full momentum 11:19:28 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 11:26:12 --- quit: mnemnion (Remote host closed the connection) 11:33:09 --- join: X-Scale (HydraIRC@89.214.140.136) joined #forth 11:36:25 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 11:37:47 --- quit: mnemnion (Remote host closed the connection) 11:43:09 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 11:48:15 what's WASM? 11:51:11 --- quit: ASau`` (Remote host closed the connection) 11:51:27 --- join: ASau`` (~user@89.15.237.20) joined #forth 11:52:27 --- quit: mnemnion (Remote host closed the connection) 11:53:24 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 11:54:51 --- quit: mnemnion (Remote host closed the connection) 11:55:01 Web Assembly - a portable bytecode standard that will (some day) run in all browsers 11:55:47 --- quit: nisstyre (Read error: Connection reset by peer) 11:55:56 First release will be Q1 of next year for most browsers. Lots of potential for things like writing a FORTH VM to do web dev in and not loose performance / size because of transpilation. 11:57:01 --- quit: neceve (Quit: Konversation terminated!) 12:07:21 oh okay 12:07:48 hm, Forth isn't exactly noted for its string-handling abilities 12:08:50 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 12:10:24 Some time ago there was "a huge potential" of writing CGI apps in Forth. And now -- WebAssembly. Okay :) 12:13:02 --- quit: mnemnion (Ping timeout: 256 seconds) 12:16:22 gordonjcp: You could implement HTML in Forth by adding the HTML tags as Forth words. That's how I parse formats in Forth, by extending Forth to support a format as a vocabulary. I don't do complicated string manipulation. 12:17:54 well, each webassembly "module" has only one instance shared between any importer of it so access control and security wise it seems rather poor (like any Indians not quick enough to Modi-fy their Rs500 and Rs1000 bills but that is offtopic) 12:22:20 --- nick: ASau`` -> ASau 12:23:52 pointfree: hm, interesting idea 12:24:26 pointfree: so you'd have what, a Forth program that just assembled up the text? 12:25:13 pointfree: or would you have some way of parsing the text and just running the forth words and passing the rest through, or something? 12:27:32 gordonjcp: In gForth I could just "include index.html" and the tags would do different things or additionally CREATE new words from unparsed text. 12:27:57 right 12:43:39 --- quit: ricky_ricardo (Ping timeout: 240 seconds) 12:45:48 --- join: ricky_ricardo (~rickyrica@2601:240:4203:ecb0:6818:6dd8:651a:83b7) joined #forth 12:51:07 --- quit: ricky_ricardo (Ping timeout: 256 seconds) 13:34:58 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 13:35:39 --- quit: mnemnion (Remote host closed the connection) 13:35:51 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 13:37:00 true-grue: thanks for the links; I'm starting to see how I misunderstood Backus's FP 13:37:42 true-grue: in my defense, I was reading those papers when university was teaching java, so just the jump tp functional programming was a big jump 13:59:36 true-grue: is the following correct 13:59:45 imperative programming is :: machine state -> machine state 13:59:57 ml / haskel lfunctional programming is :: expr -> expr ... and buidlikng up these functions 14:00:10 backus fp is :: function -> function ... and once you built a big function as entire prog, you apply it to input 14:13:41 lgstate, Basically, yes. And if you restrict the use of values (you should think about them as wires in data-flow diagram) and you have a special syntax for some important functional forms (like a white space for composing of functions) and a compiler can use them (for parallelizing and other code transformations) then you have function-level PL. 14:14:57 --- quit: mnemnion (Remote host closed the connection) 14:20:46 true-grue: is there a real language built around this? I'd like to work through a number of tutorials step by step (the backus paper seems a bit theoretical in showing how FP works) 14:20:54 (this, btw, is very fasicnating) 14:21:16 most of the 'tedious' nature I felt in clojure was 'naming variables', making me want haskell, but I think this 'backus fp' thing is even closer 14:27:40 lgstate, Have you seen my link about Faust language? 14:29:15 I'm aware about some functional-level languages, but can't say that I'm satisfied with any of them. Here is geometry language, for example: http://www.plasm.net/docs/tutorial/introduction_to_fl_and_plas.html 14:31:31 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 14:31:36 Joy is closer to Forth http://www.kevinalbrecht.com/code/joy-mirror/j00ovr.html 14:32:55 You may find this interesting too: http://home.pipeline.com/~hbaker1/ForthStack.html 14:40:17 --- quit: mnemnion (Remote host closed the connection) 14:42:19 --- quit: nighty (Quit: Disappears in a puff of smoke) 14:42:34 true-grue: looking at it now 14:42:48 true-grue: I feel like this is such a brilliant idea with equally disorganixed documentation :-) 14:46:52 lgstate, Here are basic functional forms in Faust 14:46:52 function ~ function "recursive composition" 14:46:52 function , function "parallel composition" 14:46:52 function : function "sequential composition" 14:46:52 function <: function "split composition" 14:46:53 function :> function "merge composition" 14:50:38 ricky_ricardo: I don't know. Here are his repositories https://github.com/flagxor?tab=repositories 14:51:40 --- join: nal (~nal@adsl-64-237-234-165.prtc.net) joined #forth 14:52:32 true-grue: I will go study this 14:52:45 the paper also mentioned APL (I didn't get get the anlogy), biut it seems very much like 'apl adverbs' 14:52:48 whikch modifies the 'verbs' 14:52:54 this is fasicnating 14:53:35 lgstate, Yes. I think Backus got the basis for his ideas from APL. 14:54:06 that makes alot of sense 14:54:21 the paper has a dot product example, showikng the imperative for loop example and the apl example 14:54:33 and after the apl example, I couldnt' answer "damn, this is short, how can you do better than this?" 14:57:23 lgstate, Interesting quote about Faust: 14:57:28 "It's the only practical FPL for signal processing that I know which generates code which can compete with carefully handcoded signal processing algorithms." 14:58:25 So, Backus was right after all. Although he was misunderstood by some famous scientists. 14:58:40 true-grue: I can believe that; when you're 'stacking' layers and layers of functions on each other, the compiler has more info 14:58:47 and can do 'symbolic simplifications' 14:58:57 You can find some interesting debates between Dijkstra and Backus about the lecture. 14:58:58 that are hard to see when every one is globla state -> global state -> global state -> global state 14:59:21 i heard the two of them had legendary egos 15:03:02 Yes. And you have a selected and predefined number of ways to do this stacking. It's very important for the compiler. It's somewhat similar to the idea of structured programming, but on the next level. Maybe also the next level after the introducing SSA/CPS. 15:05:57 But it has its drawbacks too. Faust got some popularity, due to its relative small domain of use. It's a bit hard to imagine a popular general purpose functional-level PL. At least, AFAIK, nobody made such language yet. 15:27:15 --- quit: newcup (Ping timeout: 260 seconds) 15:53:51 --- join: nighty (~nighty@p001.gate.atson.jp) joined #forth 16:06:29 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 16:08:02 --- quit: mnemnion (Remote host closed the connection) 16:08:14 --- join: hellcode (~hellcode@189.180.50.26) joined #forth 16:20:18 --- quit: true-grue (Read error: Connection reset by peer) 16:20:49 --- quit: nal (Quit: WeeChat 1.4) 16:21:27 --- join: nal (~nal@adsl-64-237-234-165.prtc.net) joined #forth 16:25:12 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 16:25:14 --- quit: mnemnion (Remote host closed the connection) 16:25:28 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 16:50:32 --- quit: mnemnion (Remote host closed the connection) 17:00:59 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 17:09:41 --- quit: mnemnion (Remote host closed the connection) 17:10:28 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 17:13:12 --- quit: mnemnion (Remote host closed the connection) 17:21:55 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 17:28:34 --- quit: mnemnion (Remote host closed the connection) 17:32:18 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 17:59:23 --- quit: mnemnion (Remote host closed the connection) 18:13:09 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 18:17:38 --- join: neceve (~ncv@unaffiliated/neceve) joined #forth 18:17:59 --- quit: mnemnion (Remote host closed the connection) 18:20:30 --- quit: hellcode (Quit: leaving) 18:27:25 --- join: mnemnion (~mnemnion@152.179.131.166) joined #forth 18:31:46 --- quit: mnemnion (Ping timeout: 260 seconds) 18:41:44 --- join: mnemnion (~mnemnion@71.198.73.193) joined #forth 18:46:14 --- quit: mnemnion (Ping timeout: 260 seconds) 19:28:39 --- quit: Zarutian (Quit: Zarutian) 19:31:48 --- join: ricky_ricardo (~rickyrica@2601:240:4203:ecb0:31f7:86e3:b241:3ddc) joined #forth 20:28:59 What's the fastest way to make a string constant in GForth? 20:29:54 They mention it in the GForth manual, but don't show anything for it. I basically want to just compile a string into a dictionary entry and CREATE a word that pushes its start address and length onto the stack when called 20:30:19 --- join: mnemnion (~mnemnion@71.198.73.193) joined #forth 21:15:14 --- quit: nal (Quit: WeeChat 1.4) 21:19:27 --- quit: ASau (Remote host closed the connection) 21:19:40 --- join: ASau (~user@netbsd/developers/asau) joined #forth 21:23:02 --- quit: ricky_ricardo (Ping timeout: 260 seconds) 21:23:19 --- quit: rgrinberg (Ping timeout: 260 seconds) 21:43:27 ricky_ricardo: I don't know if there's already something, but you could do this : sconstant create s, does> count ; s" hello world" sconstant hello 21:50:02 --- quit: neceve (Quit: Konversation terminated!) 22:00:11 --- quit: mnemnion (Remote host closed the connection) 22:00:47 --- join: mnemnion (~mnemnion@71.198.73.193) joined #forth 22:03:44 --- quit: ASau (Remote host closed the connection) 22:04:00 --- join: ASau (~user@netbsd/developers/asau) joined #forth 22:05:12 --- quit: mnemnion (Ping timeout: 250 seconds) 22:07:31 --- quit: ASau (Remote host closed the connection) 22:08:16 --- join: ASau (~user@netbsd/developers/asau) joined #forth 22:12:34 --- quit: ASau (Ping timeout: 250 seconds) 23:39:45 --- join: proteusguy (~proteusgu@node-43a.pool-182-52.dynamic.totbb.net) joined #forth 23:39:46 --- mode: ChanServ set +v proteusguy 23:59:59 --- log: ended forth/16.11.10