Commit Graph

282 Commits

Author SHA1 Message Date
Sage Vaillancourt 06389ac5fc Manual specification of color-highlighting order. 2022-03-24 16:59:57 -04:00
Sage Vaillancourt 6c7132aa46 Exit code of `./pl --run-tests` is the number of failed tests. 2022-03-23 01:02:27 -04:00
Sage Vaillancourt d743970b1a Tweak (eval) to accept SLIST arguments.
Tweak implicit-cat detection.
Explicit empty-string notation in test display.
A couple more tests.
2022-03-23 01:00:11 -04:00
Sage Vaillancourt bf2b9504a6 Better handle deeply nested help highlighting. 2022-03-22 12:01:24 -04:00
Sage Vaillancourt 86f3f4b32c Do some simple depth highlighting in help text. 2022-03-22 11:54:26 -04:00
Sage Vaillancourt 5a622736d3 Handle more testing stuff statically.
Remove fnt and just have centralized fn.
Longer printObj temp string.
`?` now shows tests.
Add more internal testing.
2022-03-22 11:45:02 -04:00
Sage Vaillancourt 097cbf6a5c Start some internal testing frameworking. 2022-03-21 12:33:57 -04:00
Sage Vaillancourt 3bf65577c0 Add help text for STANDALONE.
Pull most user functions into the new plfunc.
Could integrate some tests directly into pl with --run-tests
2022-03-20 03:50:43 -04:00
Sage Vaillancourt 30e8c87e66 General code clean-up. 2022-03-19 22:25:20 -04:00
Sage Vaillancourt 4733e1172e Fix uncaught mismatched paren error.
Add test against that error behavior.
Remove bits of unused code from web.c and tests.sh
2022-03-19 21:53:18 -04:00
Sage Vaillancourt c9be701b19 Fix no-param lambda environment bug.
Put allocation cap behind an ifdef
2022-03-19 21:28:17 -04:00
Sage Vaillancourt 9da4649a27 Several small additions.
Add basic allocation tracking.
Add extra error context
  - more useful for debugging the language than programs written in it
Let reduce work on a single non-list item. May be removed.
Add more testing.
Add test filtering.
Fix triple-quotes.
2022-03-18 16:12:39 -04:00
Sage Vaillancourt ee8eaf2d28 Fix web struct handling.
Typedef to handle different versions of libmicrohttpd.
Add getStructIndex().
Fix small print() mem leak.
2022-03-18 11:23:19 -04:00
Sage Vaillancourt b4584fa377 Start work on adding queryParams, etc. 2022-03-17 16:59:08 -04:00
Sage Vaillancourt 13a7ad97b5 Correct known memory leaks. 2022-03-17 13:23:19 -04:00
Sage Vaillancourt 011ed937fe Some memory fixes.
Also removed unnecessary comments.
2022-03-16 23:31:14 -04:00
Sage Vaillancourt bbb2cb471e Improve testing.
Remove explicit endBlock function.
Test some of the new features.
2022-03-16 16:57:37 -04:00
Sage Vaillancourt 711719289f Several changes.
Add `reduce` and `islist`.
 - Reduce is broken with lambdas for some reason.
Remove `switch` from lib (breaks `penv`).
More detailed lambda to-stringing.
A bit of fixing for lambdas that return lambdas.
Re-org Object fields for simpler visual debugging.
Let `cat` work with one argument.
Add prompt option for `inp`.
Some more refinement of the webby.pl example.
2022-03-16 16:50:55 -04:00
Sage Vaillancourt 7faf2ebbb3 Add POST method.
Rename `addroute` to `get`.
2022-03-15 23:22:28 -04:00
Sage Vaillancourt 4decbbbe5c Use readline history. 2022-03-15 22:47:46 -04:00
Sage Vaillancourt f37969418d Add simple web server implementation.
Adjust global Environment implementation.
Example `webby.pl` is now a simple server program.
Only limit stringNObj outside of STANDALONE implementations.
Larger catObjects sizes.
Parsing files ignores semicolons inside of quotes.
2022-03-15 21:48:04 -04:00
Sage Vaillancourt b390e272a7 Remove Makefile testing code.
Revert disabled printd() to a semicolon.
2022-03-15 16:53:34 -04:00
Sage Vaillancourt 2cc97288bf Add hard-coded readline REPL.
...the library issue was not Ubuntu's fault.
2022-03-15 16:51:23 -04:00
Sage Vaillancourt a59ce1646f More comprehensive webby.pl
Allow for longer strings, but there's still another limiting element somewhere.
2022-03-15 16:03:23 -04:00
Sage Vaillancourt 1d5621923c Further flesh-out structs.
Temporarily disable http due to buggy Ubuntu libmicrohttpd.
Add a way to access their fields with `'s`.
 - Uses some fairly hacky parseAtom additions. Needs to be refined.
Add structCapacity to Environment.
Add global Environment pointer.
Use structDef indexes instead of direct pointers.
 - Easier to increase capacity this way
strcpy struct field names
2022-03-15 15:27:02 -04:00
Sage Vaillancourt 11f39bf136 Add simple webserver functionality. 2022-03-14 23:46:20 -04:00
Sage Vaillancourt 6c8ff04711 Extremely barebones struct object implementation. 2022-03-14 16:52:08 -04:00
Sage Vaillancourt e2c977e95a Finally some consistent styling.
Centralized printf/printd defines in object.h
Removed null/isList checking from FOR_POINTER_IN_LIST
2022-01-07 16:55:03 -05:00
Sage Vaillancourt 8d22bf575c Add history and ok/err functionality to REPL. 2021-12-15 14:40:49 -05:00
Sage Vaillancourt f3a69989fa Better switch functionality. 2021-12-15 14:39:13 -05:00
Sage Vaillancourt 55d39431b1 Add TYPE_SLIST.
Not yet stable, but allows manipulation of lists without immediate
evaluation.
2021-12-15 14:38:52 -05:00
Sage Vaillancourt 5261880ebb Fix test quoting. 2021-12-15 14:27:01 -05:00
Sage Vaillancourt d73247a471 Fix deleteEnv null-pointer bug. 2021-12-15 14:25:47 -05:00
Sage Vaillancourt c0ad4481bd Fix tokens.c missing-error-code bug. 2021-12-15 14:25:09 -05:00
Sage Vaillancourt d36f1bf162 Remove single-quote support for strings.
Add triple-quote support.
Switch to structs for handling errors.
2021-12-13 10:47:35 -05:00
Sage Vaillancourt 49bf4aa1a2 Add system calls and some char processing.
Color REPL error output.
Add 'clear' shorthand to REPL.
Add basic switch to lib.
2021-12-10 16:38:44 -05:00
Sage Vaillancourt 08432275c8 Correct and re-enable environment tests 2021-07-22 15:51:42 -04:00
= ea04af7b6b Remove unused BOUNDS type from PebbleObject 2021-07-22 17:08:53 +01:00
= 10b2bc6938 Update README for 0.4 2021-07-22 17:07:44 +01:00
= 787aec6f95 Remove in-memory duplication of pebbles' code text 2021-07-22 14:34:26 +01:00
= 723acc6b2e Version bump to 0.4 2021-07-21 20:52:09 +01:00
= 2cbe610b95 Correct FORCE_TEXT 2021-07-21 20:48:41 +01:00
= 58f73bc0f8 Simpler SIMPLE_ERRORS and new LOW_MEM FORCE_TEXT 2021-07-21 19:49:29 +01:00
= 3d8e2d30d4 Add LOW_MEM and SIMPLE_ERRORS flags for aplite.
LOW_MEM drops some functionality (like `defe`) for very low memory devices like
aplite. SIMPLE_ERRORS is enabled when compiling with LOW_MEM, and overrides the
new error-with-context functionality with older, less intensive methods.
Also marked more code for standalone compilation only.
2021-07-21 19:31:40 +01:00
= c142730837 Errors can have context to make them more useful.
External:
  Error changes.
  User windows will show string reps of all object types
Internal:
  Some re-org and renames in calc.
  Add stringNObj for more controlled string-receiving.
Note: currently aplite has a hard time with larger scripts, possibly because of
recent changes. Not sure how much can be done about it, but I'm investigating.
2021-07-21 16:26:04 +01:00
= cadb57c0f2 Add small font file 2021-07-21 16:13:16 +01:00
= 06ab491b1e Give result prefix its own definition 2021-07-16 01:33:17 +01:00
= e58e5aeaa9 Some renames and general cleanup.
Added spaces after `cat` `map`, etc.
2021-07-16 01:20:36 +01:00
= bdd8c3fae3 Add extra-small font for large amounts of text 2021-07-16 00:43:46 +01:00
= 1802542fa0 Add Pebble 2 support 2021-07-15 01:09:35 +01:00