2026-07-05 03:05:52 Could someone help me understand the difference between ANS Forth and the Forth Standard? Are these the same, or separate commitees / organizations? 2026-07-05 04:22:17 They're separate organisations; ANS Forth ("Forth 94") is ANSI; Forth 2012 is from the Forth200x committee 2026-07-05 05:44:46 Thanks lofty! 2026-07-05 07:57:30 Forth 200x is a fork of ANS 2026-07-05 07:59:07 The actual ISO (ANS) standard doesn't have interest to continue revising it so they're still the official ISO spec but haven't changed since 94 2026-07-05 09:09:16 Looks like their website is now here http://www.forth200x.org/forth200x.html 2026-07-05 09:11:21 And at bottom they talk about standards organisations, saying they considered it but decided it was more important to produce something first and looks like they've not been too bothered since 2026-07-05 09:11:49 Can't blame them, making it ISO official would be a waste of their time really 2026-07-05 09:40:52 Since it wasn't mentioned here, I'd like to note that there're other international standards bodies out there besides of ISO, such as ECMA, http://ecma-international.org/ . In particular, they maintain standard for ECMAScript, the "core" language underlying JavaScript, http://262.ecma-international.org/ , and ECMA 119 is basically a copy of ISO 9660 that one can download for free. 2026-07-05 09:40:52 There're dozens more "current" ECMA standards besides, including the UDF filesystem, or ECMA 107 - the specification for the FS popularly known as "FAT16 / FAT12" (FAT32 is sadly not standardized, AFAIK.) And a number of withdrawn ones, such as the standard for BASIC. 2026-07-05 16:26:08 iv4nshm4k0v: Very true, I like ECMA 2026-07-05 16:59:12 i push my automata workshop on git hub https://github.com/cleobuline/maccam-6/tree/main/cam-8 2026-07-05 17:01:48 https://labynet.fr/videos/test.mp4 2026-07-05 17:02:19 if some one have a macintosh , he may be interressed 2026-07-05 17:02:44 there is a small forth to edit the rules 2026-07-05 17:09:06 Is this being done for a university or something? 2026-07-05 17:18:09 Octal works better in Forth, aligns with binary and doesn't have letters so you don't accidentally enter words instead of literals 2026-07-05 17:22:02 that will be a gift to the community and in send it to margolus veltas , because i love this man 2026-07-05 17:36:17 Cool 2026-07-05 17:53:56 FWIW, Pygmy allows $-prefixed hex numerals. Pretty convenient, especially considering that hex is way more common than octal in DOS/BIOS/whatever references. 2026-07-05 18:08:52 How does one implement colorforth? do you have information on it? something like movingforth but for colorforth? 2026-07-05 18:14:48 iv4nshm4k0v: I agree the prefixed numbers are pretty useful, it's in Forth 2012 / Forth 200x standards and is one of the better features 2026-07-05 18:40:41 deadmarshal: "Moving Forth" is, in part, a study of several Forth implementations existing at the time it was written. Unless I be mistaken, there ever was only one colorForth implementation; as such, I'm not sure it's possible to write something /quite/ like "Moving Forth." 2026-07-05 18:53:25 ACTION listens to http://soundoftheaviators.bandcamp.com/track/modern-mythology  2026-07-05 19:33:46 how to display the names of all files in a directory (gforth)? 2026-07-05 19:35:10 ACTION my google-fu failed :( 2026-07-05 19:35:56 Stalevar here seems to be interested in Gforth. He's been idle for a few days, though. 2026-07-05 19:36:38 oh 2026-07-05 19:36:42 ok 2026-07-05 19:39:59 iv4nshm4k0v: ah ok thanks. 2026-07-05 19:40:50 I did grep(1) for "directory" over Gforth .info files (as of latest stable from 2008), and none of the dozen or so mentions seem to have anything to do with reading directories. I /think/ Retro Forth may be better suited for system programming, but I have very little familiarity with it myself. 2026-07-05 19:40:52 akoana: S" ls" SYSTEM 2026-07-05 19:41:01 s" ls -1 ." system works, but I'm looking for a "native" solution using open-dir and read-dir... 2026-07-05 19:41:13 akoana: probably read-dir: https://gforth.org/manual/Directories.html 2026-07-05 19:41:36 thanks vel tas 2026-07-05 19:42:18 and thanks deadmarshal 2026-07-05 19:49:01 I read the manual but an example how to use read-dir would be helpful, equivalent to the system example ... s" ls -1 ." read-dir gives :1: Stack underflow 2026-07-05 19:50:52 I'd expect read-dir to take a file descriptor of a directory opened for reading from stack, and put some value corresponding to the directory entry read in its place. So you open a directory, read-dir it in a loop, printing the entries as they are read. 2026-07-05 19:55:14 akoana: This worked on my gforth https://termbin.com/zbzs 2026-07-05 19:58:22 Yeah you might want to read the reference deadmarshal sent 2026-07-05 20:00:18 Strangely enough, my Git clone from earlier this year doesn't seem to have any description of open-dir and read-dir under doc/ - just the words themselves mentioned in the words lists. 2026-07-05 20:04:05 veltas: wow, your solution works here too, great! thank you! 2026-07-05 20:09:26 I had https://termbin.com/ws0a copied from somewhere but without success, being rather a forth rookie I got stuck, the relevant gforth docs are quite terse - anyway thanks again, veltas! 2026-07-05 20:12:29 M-m; read-dir is defined, and documented, in ./prim - a file that's also gets pre-processed with M4. 2026-07-05 20:28:22 true, but sadly in test/primtest.fs there are no tests for open-dir, read-dir and close dir ... only comments like \ !! open-dir. A working example - as veltas wrote - showing how to use these words would be very helpful in the docs. 2026-07-05 20:28:43 *close-dir 2026-07-05 20:33:47 If veltas has time to spare, I suppose he can propose a patch (to test/primtest.fs)? Might need to do the copyright assignment paperwork, though. 2026-07-05 20:36:06 it would be great to have a patch like that, yes. 2026-07-05 21:07:19 iv4nshm4k0v: in retro, something like this would work `[ s:put sp ] unix:for-each-file` 2026-07-05 21:22:57 "If veltas has time to spare" lol 2026-07-05 21:23:38 Sorry not meant in a rude way just funny right now with the week I've had 2026-07-05 21:26:20 akoana: "pad 256 over" this puts PAD on top of stack, you want "dup pad 256 rot" so you've got the open directory on top 2026-07-05 21:26:45 In my example I didn't close the directory by the way, you should close-dir 2026-07-05 21:26:54 It was just sort of a proof of concept 2026-07-05 21:29:49 Also read-dir puts the number of characters read under the flag 2026-07-05 21:30:40 So when that copied example breaks out of the loop, you need to drop that count before close-dir 2026-07-05 21:31:32 And in Forth it's customary to output CR at the *start* of each line, in multi line output 2026-07-05 21:31:46 Unlike e.g. C and most langs where it's used to end every line 2026-07-05 21:33:12 freeforth is so cool 2026-07-05 21:51:48 Yeah? 2026-07-05 22:08:23 it's a fusion of forth and assembler, it's inspired by retro but it's more compact and runs on native i386, written in fasm. it has tail-call optimization just with jumps; no STATE variable. 2026-07-05 22:09:07 Cool 2026-07-05 22:12:56 it was a pain to get it to link on my system, but it did. i ended up using gcc instead of ld. `gcc -m32 -no-pie -nostartfiles -Wl,-z,execstack -o ff ff.o -ldl` 2026-07-05 22:13:06 FreeForth2 2026-07-05 22:13:21 veltas: thanks for your explanations and additions! 2026-07-05 22:14:27 fkw: I struggle to link anything with ld directly myself 2026-07-05 22:15:13 Although with all the flags you're using and I'm guessing the source is assembly, strange it didn't link 2026-07-05 22:17:18 it was fasm, the trouble came from linking dl (for FreeForth2 to be able to load dynamic libraries); maybe i could get it to compile with ld by just making sure dl is in the search path 2026-07-05 22:18:30 order of arguments is so strange with GNU/LLVM toolchain 2026-07-05 22:20:24 Agreed 2026-07-05 22:25:02 If dl is linked then don't you need glibc and to initialise the C runtime? 2026-07-05 22:25:13 FreeForth was inspired by Retro 7 & 8 IIRC. I used NASM and FASM for the implementations back then. 2026-07-05 22:27:21 Crazy how much you've influenced Forth this century crc 2026-07-05 22:33:29 Probably helps that for most of the time I used Forth I was exploring different ideas and sharing my experiments very freely 2026-07-05 22:36:42 Well that and, if you'll permit, I think you've got very good taste 2026-07-05 22:37:19 And also you've output a lot