OSDN Git Service

joypy/Thun.git
7 months agominor edits
sforman [Sat, 21 Oct 2023 05:16:21 +0000 (22:16 -0700)]
minor edits

7 months agoA little BTree.
sforman [Sat, 21 Oct 2023 02:36:41 +0000 (19:36 -0700)]
A little BTree.

Persistent (immutable) datastructure.

7 months agoA start on error reporting.
sforman [Fri, 20 Oct 2023 18:42:50 +0000 (11:42 -0700)]
A start on error reporting.

I outfitted `rest` with some error reporting and tried out exception
handling.  So far so good.

One issue is that the dictionary is not a persistent datastructure, so
if there was an "inscribe" command (it's not yet implemented for this
Scheme implementation) that might be slightly problematical.  (If an
error were to occur in an evaluation that had already entered new
definitions into the dict then those definitions would "survive" into
the rest of the REPL session (or whatever.))

I'll look into persistent dict for Scheme.

7 months agoUse Scheme symbols for Thun symbols.
sforman [Fri, 20 Oct 2023 03:54:11 +0000 (20:54 -0700)]
Use Scheme symbols for Thun symbols.

It seems more elegant that way, but I haven't tested it to find out if
it has better performance or memory usage (yet.)

7 months agoSymbols for symbols.
sforman [Sun, 15 Oct 2023 18:41:44 +0000 (11:41 -0700)]
Symbols for symbols.

This shouldn't work yet, because the parser makes Lisp symbols out of
the Thun symbols, but the match expr still has strings.  In the REPL
this fails, but in the compiled Joy binary it doesn't fail, the
interpreter interprets just fine.

7 months agoadd defs for select and small; cleaner joy-func.
sforman [Fri, 13 Oct 2023 14:42:22 +0000 (07:42 -0700)]
add defs for select and small; cleaner joy-func.

7 months agoA little more match.
sforman [Thu, 12 Oct 2023 03:36:01 +0000 (20:36 -0700)]
A little more match.

7 months agoUse match a little more.
sforman [Thu, 12 Oct 2023 03:13:02 +0000 (20:13 -0700)]
Use match a little more.

7 months agoUse match instead of cond.
sforman [Thu, 12 Oct 2023 03:01:35 +0000 (20:01 -0700)]
Use match instead of cond.

7 months agoMinor indentation change, a typo.
sforman [Tue, 10 Oct 2023 19:12:07 +0000 (12:12 -0700)]
Minor indentation change, a typo.

7 months agoRemove global stack, dict.
sforman [Tue, 10 Oct 2023 18:16:30 +0000 (11:16 -0700)]
Remove global stack, dict.

Pass them through the recursive loop instead.

7 months agoPut a bang on add-def.
sforman [Tue, 10 Oct 2023 17:43:38 +0000 (10:43 -0700)]
Put a bang on add-def.

7 months agoSome edits.
sforman [Tue, 10 Oct 2023 17:08:17 +0000 (10:08 -0700)]
Some edits.

7 months agomin and max
sforman [Mon, 9 Oct 2023 20:04:16 +0000 (13:04 -0700)]
min and max

7 months agoSome edits to some notebooks.
sforman [Mon, 9 Oct 2023 19:48:14 +0000 (12:48 -0700)]
Some edits to some notebooks.

7 months agoRun MAKE.
sforman [Mon, 9 Oct 2023 18:50:37 +0000 (11:50 -0700)]
Run MAKE.

7 months agoDerive `zip`.
sforman [Mon, 9 Oct 2023 18:45:28 +0000 (11:45 -0700)]
Derive `zip`.

7 months agoNerd Sniped
sforman [Mon, 9 Oct 2023 18:44:13 +0000 (11:44 -0700)]
Nerd Sniped

7 months agoGreat progress!
sforman [Mon, 9 Oct 2023 03:17:02 +0000 (20:17 -0700)]
Great progress!

7 months agoMore work on Ref doc, & stuff.
sforman [Mon, 9 Oct 2023 00:58:22 +0000 (17:58 -0700)]
More work on Ref doc, & stuff.

7 months agoImplement `bool` and trace for Scheme.
sforman [Mon, 9 Oct 2023 00:57:05 +0000 (17:57 -0700)]
Implement `bool` and trace for Scheme.

7 months agoTake the right number of things off of the stack.
sforman [Sun, 8 Oct 2023 20:08:34 +0000 (13:08 -0700)]
Take the right number of things off of the stack.

7 months agoNerd sniped by a silly function.
sforman [Sat, 7 Oct 2023 22:25:38 +0000 (15:25 -0700)]
Nerd sniped by a silly function.

7 months agoMinor edits; rebuild docs.
sforman [Wed, 4 Oct 2023 16:58:02 +0000 (09:58 -0700)]
Minor edits; rebuild docs.

7 months agoPrint out wobbly words.
sforman [Wed, 4 Oct 2023 15:28:53 +0000 (08:28 -0700)]
Print out wobbly words.

That have definition but no ref doc, or ref docs but no defs.

7 months agoUse slightly smaller font files. one_ref
sforman [Wed, 4 Oct 2023 03:19:31 +0000 (20:19 -0700)]
Use slightly smaller font files.

7 months agoMinor edits.
sforman [Wed, 4 Oct 2023 03:17:04 +0000 (20:17 -0700)]
Minor edits.

7 months agoTidy?
sforman [Sun, 1 Oct 2023 19:48:25 +0000 (12:48 -0700)]
Tidy?

7 months agoA little more work on the ref doc.
sforman [Sun, 1 Oct 2023 16:21:16 +0000 (09:21 -0700)]
A little more work on the ref doc.

7 months agoMark combinators.
sforman [Sat, 30 Sep 2023 21:41:39 +0000 (14:41 -0700)]
Mark combinators.

7 months agoBuild the ref doc.
sforman [Sat, 30 Sep 2023 21:25:12 +0000 (14:25 -0700)]
Build the ref doc.

7 months agoPut interpreter on pages.
sforman [Fri, 29 Sep 2023 22:25:49 +0000 (15:25 -0700)]
Put interpreter on pages.

7 months agoGive it it's own CSS file.
sforman [Fri, 29 Sep 2023 01:35:54 +0000 (18:35 -0700)]
Give it it's own CSS file.

It's good enough for now.

7 months agoremove the individual md ref files
sforman [Thu, 28 Sep 2023 18:53:34 +0000 (11:53 -0700)]
remove the individual md ref files

7 months agoMinor edits.
sforman [Thu, 28 Sep 2023 18:36:19 +0000 (11:36 -0700)]
Minor edits.

7 months agoDiv, mod handle zero.
sforman [Sun, 24 Sep 2023 04:20:37 +0000 (21:20 -0700)]
Div, mod handle zero.

7 months agoTypo.
sforman [Sat, 23 Sep 2023 17:59:38 +0000 (10:59 -0700)]
Typo.

7 months agoElm reformatting and demo HTML page.
sforman [Sat, 23 Sep 2023 16:37:43 +0000 (09:37 -0700)]
Elm reformatting and demo HTML page.

8 months agoChange definition of uncons.
sforman [Mon, 18 Sep 2023 18:26:50 +0000 (11:26 -0700)]
Change definition of uncons.

8 months agoUse blob URL.
sforman [Thu, 7 Sep 2023 01:26:52 +0000 (18:26 -0700)]
Use blob URL.

8 months agoAdd grammar image.
sforman [Thu, 7 Sep 2023 01:24:27 +0000 (18:24 -0700)]
Add grammar image.

Made with https://jacquev6.github.io/DrawGrammar/

8 months agoElm version using BigNums.
sforman [Sat, 2 Sep 2023 18:30:18 +0000 (11:30 -0700)]
Elm version using BigNums.

This went pretty smoothly, I just followed the compiler errors after
substituting Integer for Int in the type definition.

The only tricky thing is that the div and mod functions for Integer
return Maybe Integer rather than just Integer, so I need to wrap those
or something?  (For now I just put in add to get it to compile.)

Oh, and "not equal" is not correct? The compiler didn't complain.

8 months agoLet's use bignums.
sforman [Sat, 2 Sep 2023 18:11:42 +0000 (11:11 -0700)]
Let's use bignums.

8 months agoDon't use andThen.
sforman [Sat, 2 Sep 2023 16:44:57 +0000 (09:44 -0700)]
Don't use andThen.

It's less clear than spelling it all out.

8 months agoChaining with andThen works but is ugly.
sforman [Sat, 2 Sep 2023 16:38:15 +0000 (09:38 -0700)]
Chaining with andThen works but is ugly.

It's lees clear to me what's going on, and I wrote it.

8 months agoI think Scheme?
sforman [Thu, 31 Aug 2023 17:42:29 +0000 (10:42 -0700)]
I think Scheme?

8 months agoRebuilt C.
sforman [Thu, 31 Aug 2023 02:57:57 +0000 (19:57 -0700)]
Rebuilt C.

8 months agoCompiling Thun to Python.
sforman [Thu, 31 Aug 2023 01:54:49 +0000 (18:54 -0700)]
Compiling Thun to Python.

Not all of the words that compiled with the old defs.txt compiled with
the latest, so we're keeping the old one in here until I can trace down
the issues.

8 months agopow
sforman [Thu, 31 Aug 2023 01:52:26 +0000 (18:52 -0700)]
pow

8 months agoUpdate Nim defs.txt.
sforman [Thu, 31 Aug 2023 01:46:51 +0000 (18:46 -0700)]
Update Nim defs.txt.

8 months agoSimple linear power function.
sforman [Thu, 31 Aug 2023 01:44:55 +0000 (18:44 -0700)]
Simple linear power function.

8 months agoTHe old compiler-to-Python.
sforman [Wed, 30 Aug 2023 23:57:48 +0000 (16:57 -0700)]
THe old compiler-to-Python.

8 months agoRename BigNums.
sforman [Wed, 30 Aug 2023 17:42:29 +0000 (10:42 -0700)]
Rename BigNums.

8 months agoAdd a README to the docs/ dir.
sforman [Wed, 30 Aug 2023 14:26:47 +0000 (07:26 -0700)]
Add a README to the docs/ dir.

8 months agoTest calling dip on non-quote.
sforman [Wed, 30 Aug 2023 14:25:11 +0000 (07:25 -0700)]
Test calling dip on non-quote.

8 months agoI just realized these all refer to the old package organization.
sforman [Tue, 29 Aug 2023 13:12:51 +0000 (06:12 -0700)]
I just realized these all refer to the old package organization.

8 months agoBetter exceptions.
sforman [Tue, 29 Aug 2023 03:46:19 +0000 (20:46 -0700)]
Better exceptions.

8 months agoExample of infra evaluation.
sforman [Sat, 26 Aug 2023 17:56:29 +0000 (10:56 -0700)]
Example of infra evaluation.

8 months agoNote on Variations
sforman [Sat, 26 Aug 2023 17:56:21 +0000 (10:56 -0700)]
Note on Variations

9 months agoMinor edits.
sforman [Tue, 22 Aug 2023 00:58:47 +0000 (17:58 -0700)]
Minor edits.

9 months agoRebuilt C interpreter.
sforman [Mon, 21 Aug 2023 16:53:24 +0000 (09:53 -0700)]
Rebuilt C interpreter.

9 months agoFinished up Generator_Programs.md
sforman [Mon, 21 Aug 2023 00:21:49 +0000 (17:21 -0700)]
Finished up Generator_Programs.md

9 months agoREADME for Chicken Scheme.
sforman [Sun, 20 Aug 2023 17:24:29 +0000 (10:24 -0700)]
README for Chicken Scheme.

9 months agosort
sforman [Sat, 19 Aug 2023 00:09:08 +0000 (17:09 -0700)]
sort

9 months agoSome scratch source
sforman [Sat, 19 Aug 2023 00:00:13 +0000 (17:00 -0700)]
Some scratch source

from editing BigNums notebook.

9 months agoFiglet headings.
sforman [Fri, 18 Aug 2023 23:59:32 +0000 (16:59 -0700)]
Figlet headings.

9 months agoMinor CSS changes.
sforman [Fri, 18 Aug 2023 23:58:25 +0000 (16:58 -0700)]
Minor CSS changes.

9 months agoEdits on BigNums notebook.
sforman [Fri, 18 Aug 2023 23:57:54 +0000 (16:57 -0700)]
Edits on BigNums notebook.

9 months agoAbout 2/5ths done.
sforman [Thu, 17 Aug 2023 19:09:23 +0000 (12:09 -0700)]
About 2/5ths done.

9 months agoAdd definition for xor.
sforman [Wed, 16 Aug 2023 17:05:30 +0000 (10:05 -0700)]
Add definition for xor.

9 months agoWorking on the notebooks.
sforman [Wed, 16 Aug 2023 17:04:52 +0000 (10:04 -0700)]
Working on the notebooks.

9 months agoUpdating notebooks
sforman [Mon, 14 Aug 2023 16:18:04 +0000 (09:18 -0700)]
Updating notebooks

to not use Jupyter because I can't figure out how to use the Joy kernel.

9 months agoWorking on the website for Thun.
sforman [Sun, 13 Aug 2023 21:30:57 +0000 (14:30 -0700)]
Working on the website for Thun.

I'm going to eventually update the old Sphinx-generated site on OSDN.

9 months agocleanup
sforman [Sun, 13 Aug 2023 15:49:20 +0000 (08:49 -0700)]
cleanup

9 months agoPut this over there.
sforman [Sun, 13 Aug 2023 15:48:06 +0000 (08:48 -0700)]
Put this over there.

9 months agoMinor edits.
sforman [Sun, 13 Aug 2023 15:47:16 +0000 (08:47 -0700)]
Minor edits.

9 months agoMessing around with type inference.
sforman [Sat, 12 Aug 2023 23:45:59 +0000 (16:45 -0700)]
Messing around with type inference.

What if we insist that both branches of a branch have compatible types?

For one thing `[+] [* +] branch` leads to a circular term which, when
printed, goes into a loop: "int,int,int,...".  Hmm...

9 months agofor-each
sforman [Sat, 12 Aug 2023 21:09:44 +0000 (14:09 -0700)]
for-each

9 months agoA crude main loop.
sforman [Sat, 12 Aug 2023 20:03:42 +0000 (13:03 -0700)]
A crude main loop.

I know there are better ways to do this, but I don't know what they are
yet.  Maybe a "do" loop?  Anyway, this works, although it doesn't catch
errors yet.

9 months agoMinor edit.
sforman [Sat, 12 Aug 2023 19:55:25 +0000 (12:55 -0700)]
Minor edit.

9 months agoLittle updates to the spec doc.
sforman [Sat, 12 Aug 2023 17:36:19 +0000 (10:36 -0700)]
Little updates to the spec doc.

9 months agoMinor edits.
sforman [Sat, 12 Aug 2023 15:40:55 +0000 (08:40 -0700)]
Minor edits.

9 months agoUpdate defs.scm
sforman [Sat, 12 Aug 2023 15:26:59 +0000 (08:26 -0700)]
Update defs.scm

9 months agoMerge in the test suite.
sforman [Sat, 12 Aug 2023 15:19:54 +0000 (08:19 -0700)]
Merge in the test suite.

Why not?

(I have a slow tide, expand into pieces, contract into units, and back
again.  This is part of a contract and unify phase.)

9 months agoMath ops, definitions for left- and right-shift.
sforman [Sat, 12 Aug 2023 15:04:21 +0000 (08:04 -0700)]
Math ops, definitions for left- and right-shift.

9 months agomul div mod add sub in Nim
sforman [Sat, 12 Aug 2023 14:54:33 +0000 (07:54 -0700)]
mul div mod add sub in Nim

9 months agofirst rest
sforman [Sat, 12 Aug 2023 06:02:46 +0000 (23:02 -0700)]
first rest

9 months agoconcat cons comparison
sforman [Sat, 12 Aug 2023 05:48:25 +0000 (22:48 -0700)]
concat cons comparison

9 months agoloop
sforman [Sat, 12 Aug 2023 04:27:41 +0000 (21:27 -0700)]
loop

9 months agobranch and refactor simple functions.
sforman [Sat, 12 Aug 2023 04:15:26 +0000 (21:15 -0700)]
branch and refactor simple functions.

The refactor should be a macro but I don't know how to write those yet
(apparently there are different macros systems...  ooo la la!)

9 months agodip
sforman [Sat, 12 Aug 2023 03:47:53 +0000 (20:47 -0700)]
dip

9 months agoi
sforman [Sat, 12 Aug 2023 03:45:25 +0000 (20:45 -0700)]
i

9 months agoswap
sforman [Sat, 12 Aug 2023 03:38:01 +0000 (20:38 -0700)]
swap

9 months agopop
sforman [Sat, 12 Aug 2023 03:34:40 +0000 (20:34 -0700)]
pop

9 months agostack, swaack
sforman [Fri, 11 Aug 2023 18:11:51 +0000 (11:11 -0700)]
stack, swaack

9 months agoAdd copyleft notice.
sforman [Fri, 11 Aug 2023 18:03:00 +0000 (11:03 -0700)]
Add copyleft notice.

9 months agoLoad defs at compile time.
sforman [Fri, 11 Aug 2023 17:48:33 +0000 (10:48 -0700)]
Load defs at compile time.

I don't really know the proper way to do this, but I managed to whump
something up.

9 months agoEvaluate definitions.
sforman [Fri, 11 Aug 2023 17:31:53 +0000 (10:31 -0700)]
Evaluate definitions.

9 months agoConvert defs.txt to defs.scm.
sforman [Fri, 11 Aug 2023 17:15:31 +0000 (10:15 -0700)]
Convert defs.txt to defs.scm.

Gonna need a makefile.

9 months agoLoad defs from defs.txt.
sforman [Fri, 11 Aug 2023 15:50:00 +0000 (08:50 -0700)]
Load defs from defs.txt.

They are loaded at runtime though :(  shouldn't be too hard to fix that?