Calvin Rose
67f1872f4a
Expose debugger-env
...
This makes it easier/possible to use the debugging
functionality in a more flexible way.
2020-04-27 23:32:21 -05:00
Calvin Rose
8bbb7907d6
Run parser error handler in the correct env in run-context.
2020-04-27 20:29:16 -05:00
Calvin Rose
6b0f93ce8a
Update documentation for the -q flag.
2020-04-27 18:57:53 -05:00
Calvin Rose
80f19a0ab7
Fix behavior of -q flag.
...
Don't surpress errors at the repl.
2020-04-27 18:12:22 -05:00
Calvin Rose
d2ebf4b52d
Merge branch 'net'
2020-04-26 12:27:37 -05:00
Calvin Rose
ce7d51f9be
Add dedent to core.
...
Makes longstrings easier to use - can be combined with comptime
for overhead free long strings.
2020-04-26 11:53:26 -05:00
Calvin Rose
9bc5ac05c4
Add the parse function.
2020-04-25 12:46:32 -04:00
Calvin Rose
84974d6c56
Make repl printing work from current environment.
...
Although this "unprotects" output in the repl, people
in a repl usually want control, not protection.
2020-04-24 22:29:02 -05:00
Calvin Rose
c335bf5dc5
Update doc doc.
2020-04-23 12:15:12 -05:00
Calvin Rose
9b5c6112e5
The -q option no longer disables repl output.
2020-04-20 19:28:30 -05:00
Calvin Rose
42c257d0fc
Merge branch 'master' into net
2020-04-19 13:38:51 -05:00
Calvin Rose
122c77dbf6
Merge pull request #353 from andrewchambers/require
...
Fix outdated require docstring.
2020-04-19 10:44:37 -04:00
Calvin Rose
3c66cab4e7
Remove extra binding in require.
2020-04-19 09:44:02 -05:00
Calvin Rose
5c612095a1
Address #352 , #351 , Use :source argument in dofile
...
Also re-add circular dependency detection.
2020-04-19 09:38:18 -05:00
Calvin Rose
3e60e82529
Add circular dependency detection.
...
This detection will not stop compilation, as errors
in general do not stop compilation unless exit on error
is passed inside an import, but should notify the user something
is going on.
2020-04-19 09:35:14 -05:00
Calvin Rose
60f8dd0bfc
Renable :source argument to dofile.
...
Allows for some more interesting usage of
loaders.
2020-04-19 08:54:24 -05:00
Andrew Chambers
2a7008a82c
Fix outdated require docstring.
2020-04-19 23:02:35 +12:00
Calvin Rose
4ac382e553
Add alias JANET_SIGNAL_EVENT.
2020-04-17 16:27:02 -05:00
Calvin Rose
596111c988
Merge branch 'master' into net
2020-04-17 15:08:26 -05:00
Calvin Rose
3eb84fcb13
Fix some typos, make jpm repl work without a project.janet.
2020-04-16 12:11:17 -05:00
Calvin Rose
93fc11ea21
Add edefer.
...
Also improve error messages from vm internal errors.
(Show bad value, not its type).
2020-04-13 20:24:11 -05:00
Calvin Rose
1d13095d19
Merge pull request #340 from pepe/get-vs-in-last
...
Fix last for empty collection, add tests
2020-04-10 19:03:21 -05:00
Calvin Rose
5ed76f197a
Differentiate error from resume and error from resumed fiber.
2020-04-10 18:29:10 -05:00
Calvin Rose
e1f4cadf41
Add debugger to the core repl.
...
Debugger functions are prefixed by periods.
2020-04-10 17:20:23 -05:00
Calvin Rose
3b0e6357ad
Make Ctrl-G in repl show docstring for symbol.
...
Can be used to browse docs without poluting your repl session.
2020-04-10 11:36:23 -05:00
Calvin Rose
02f17bd4e4
Add sort-by and sorted-by.
2020-04-09 20:43:51 -05:00
Josef Pospíšil
b63a0796fd
Fix last for empty collection, add tests
2020-04-09 14:35:57 +02:00
Calvin Rose
081d132538
Address #321
...
Also improve docs for dofile and related functions.
2020-04-04 21:17:15 -05:00
DEADB17
57b08a57a0
Corret typo and match wording for consistency
2020-03-31 23:32:17 -04:00
Josef Pospíšil
b6b70d54ef
Fix typo flie
2020-03-31 15:31:27 +02:00
Calvin Rose
244566ccd4
Remove manual feature definitions in boot.
...
Instead, reuse features as defined in features.h
2020-03-31 07:52:20 -05:00
Calvin Rose
ff163a5ae4
Use modulo instead of remainder for even?/odd?.
...
Works better for negative and fractional numbers.
2020-03-28 10:23:28 -05:00
Calvin Rose
65379741f7
Address edge case of reduce2 when ind is empty.
...
Same for accumulate 2.
2020-03-27 12:45:40 -05:00
Calvin Rose
3eb0927a2b
Add accumulate(2) and reduce2
...
These functions are variations on reduce and can be quite useful.
Improve error message for jpm as well.
2020-03-26 21:35:11 -05:00
Calvin Rose
3d1de237f6
Several changes to the os module.
...
- Add os/symlink
- Add os/realpath
2020-03-24 19:47:21 -05:00
Calvin Rose
77343e02e9
Fixes #304
...
Add chr macro.
2020-03-10 22:46:50 -05:00
Calvin Rose
90b3730a0a
Merge branch 'master' into net
2020-03-07 13:34:13 -06:00
Calvin Rose
d3b9b8d452
For #293 , correct wildcards in dictinoaries.
2020-03-07 10:13:10 -06:00
Calvin Rose
c864828735
Address #293 - wildcard to match macro.
...
The _ symbol will match any value without creating a binding.
2020-03-07 09:40:02 -06:00
Calvin Rose
e0c9910d85
Add :range-to and :down-to to loop.
...
Fully inclusive ranges are generally useful and
do not complicate implementation much.
2020-03-07 09:34:11 -06:00
Calvin Rose
e351dde651
Update CHANGELOG.md and docs for loop and pp.
2020-03-06 17:12:06 -06:00
Calvin Rose
6123c41f13
Harden semantics for and and or macros.
...
There was perviously a bit of fuzziness on returning false/nil
from these macros that has been removed.
2020-03-06 08:37:59 -06:00
Calvin Rose
8f1527712e
Merge branch 'master' into net
2020-03-05 18:08:35 -06:00
Calvin Rose
47e8f669f5
Fix match behavior for lone nil.
2020-03-05 09:35:00 -06:00
Calvin Rose
10ec319c32
Add better debug info to amalgamated source.
2020-02-27 00:16:54 -06:00
Calvin Rose
734c85d7ef
Properly handle recursion with labels.
...
Use an empty buffer, which has pointer equality semantics, for
tag from a label.
2020-02-23 17:35:01 -06:00
Calvin Rose
05bd5767de
Add label macro.
...
A lexically scoped version of prompt is often useful.
2020-02-23 17:15:04 -06:00
Calvin Rose
59d288c429
Add prompt
and return
.
...
User friendly delimited continuations. While this was doable with
signals before, this does not require C and will play nicely with
existing error handling, defers, and with statements.
2020-02-23 16:46:54 -06:00
Calvin Rose
6a13703e32
Add signal
and fiber/can-resume?
.
...
These additions, along with the change that user signals 0-4 cannot
be resumed, allow delimited continuation semantics, while repsecting
existing forms like `defer`, `with`, `with-vars`, etc.
2020-02-23 13:31:27 -06:00
Calvin Rose
aaabca6fc7
Make flychecker handle more kinds of defs.
...
This should help when redefining certain forms. Will also
not do functional arity checking against nil forms, as that
is the default value when a def doesn't evaluate.
2020-02-21 21:20:40 -06:00