1
0
mirror of https://github.com/janet-lang/janet synced 2024-06-29 00:23:18 +00:00
Commit Graph

188 Commits

Author SHA1 Message Date
Calvin Rose
ce9cd4fcef Issue #113 Color console support for windows 10
Use SetConsoleMode winapi function to enable ANSI
escape codes if we can.
2019-05-26 22:31:30 -04:00
Calvin Rose
97ad4c4f89 Update manpage and make -k mode not exit on error. 2019-05-19 15:20:59 -04:00
Adam Schwalm
f444bd25ef Add a 'compile-only' flag to the command line
This allows syntax checkers like the emacs 'flycheck-mode' to check
the source without side effects.
2019-05-19 12:55:28 -05:00
Calvin Rose
1cfc7b3b0d Add preliminary debugger to default repl.
Also upddate colors, and fix formatting.
2019-05-02 17:11:30 -04:00
Calvin Rose
2d7df6b78e Many changes for adding dynamic (fiber-level) scope.
- Allow passing a table to fibers, which make fiber level scope easier.
- Add fiber/getenv, fiber/setenv, dyn, and setdyn
- Remove meta, *env*, and *doc-width*
- Some functions changed dignatures, and no longer take an env
2019-04-16 15:41:45 -04:00
Calvin Rose
082639319e Add colors to repl and string/format.
This makes the repl look nicer using ANSI
color codes, which are widely supported. The codes
can also be turned off via the -m flag.
2019-03-24 15:00:22 -04:00
Calvin Rose
a363dce943 Allow proper overriding of cfunctions in the core.
Allow overriding functions in the core libray to provide better
functionality on startup. Used to include our getline function in
the repl but use a simpler version in the core library.
2019-03-08 11:39:18 -05:00
Calvin Rose
9d4effc02e Add make format to format code.
A consistent style should help with contributors and
readability. We use astyle as the formatter as can make a pretty
good approximation of the current style and my preferred style.

Astyle can be found at http://astyle.sourceforge.net/astyle.html
2019-02-19 20:51:34 -05:00
Calvin Rose
ed72dcf82d Rename the header <janet/janet.h> to <janet.h>
Makes it easier to use and remember, and makes the
variable `module/*headerpath*` make more sense.
2019-02-18 20:13:35 -05:00
Calvin Rose
8d9a88e759 Add JANET_PATH back in. 2019-02-18 15:31:15 -05:00
Calvin Rose
6af5800d21 Add -m option to command line
The -m option set the default system path for finding libraries
for that invocation of Janet.
2019-02-18 15:11:59 -05:00
Calvin Rose
3b6ff3c09a Add -c option to main client
This allows compile janet source modules to images.
2019-02-16 21:55:53 -05:00
Calvin Rose
7ba925c50a Make getline more useful. 2019-01-31 12:34:22 -05:00
Calvin Rose
737b2449f0 Update highlight and the mainclient. 2019-01-20 10:05:51 -05:00
Calvin Rose
b84b0e4828 Expose more of the module system.
The system path can more easily modified at runtime,
and the module/cache and module/loading tables are now exposed.
Properly cache native modules as well.
2019-01-18 12:04:34 -05:00
Calvin Rose
84fb07dd5a Add quiet option to main client. 2019-01-10 17:10:12 -05:00
Calvin Rose
6f3bc3d577 Update copyright date, fix types, remove trailing whitespace. 2019-01-06 03:23:03 -05:00
Calvin Rose
338b31f5a2 Add janet_fixarity. Update emscripten source. 2019-01-05 20:45:24 -05:00
Calvin Rose
b60e3e302a Update C API to use friendlier functions rather than macros.
Error handling is implemented with setjmp/longjmp so code
can be more concise. This required a very large but straight forward refactor for all
of the libraries.
2019-01-05 20:09:03 -05:00
Calvin Rose
8dde89126e Fix -s flag in janet binary. 2018-12-30 18:23:29 -05:00
Calvin Rose
56927e1b81 Fix -e option. 2018-12-30 17:51:15 -05:00
Calvin Rose
2bcedd5920 Remove indexing with numeric constants from janet. 2018-12-28 23:44:39 -05:00
Calvin Rose
03dbd79165 Rename the := special form to set so it does not look like a keyword. 2018-12-16 21:57:32 -05:00
Calvin Rose
e8c0dcd14e Make source mapping use byte offset instead of line and col
for better debugging support in repl. Add debug module for better
debugging support.
2018-12-13 18:46:53 -05:00
Calvin Rose
6185af7227 Try to remove build issues on windows. 2018-12-08 17:20:24 -05:00
Calvin Rose
16e514b351 Update version schema - now have version number
and build number.
2018-12-08 14:17:03 -05:00
Calvin Rose
7668cd5772 Don't use generated headers for embedded janet
code, use object files.
2018-12-06 14:30:11 -05:00
Calvin Rose
4e4dd31164 Change syntax for namespaces.
Add quasiquote, unquote, and unquote-splicing
as specials rather than a macro.
2018-11-30 22:49:21 -05:00
Calvin Rose
25c50f5026 Fix repl default chunks. 2018-11-30 14:17:10 -05:00
Calvin Rose
d4ee760b3e Change format for declaring flexible arity functions. 2018-11-25 14:03:00 -05:00
Calvin Rose
4c4eff9390 Replace cast with type pun. 2018-11-18 14:17:50 -05:00
Calvin Rose
4d119e4e03 Begin adding more complete documentation. 2018-11-15 15:45:41 -05:00
Calvin Rose
2a127af1ca A few fixes to things like macro expand, etc. 2018-11-07 22:27:06 -05:00
Calvin Rose
853a839f6c Add git commit hash to build to get version. 2018-10-31 16:21:21 -04:00
Calvin Rose
98f2c6feab Add lookups for marshalling and unmarshalling.
Allow generating lookup tables from the current environment.
2018-10-21 01:35:07 -04:00
Calvin Rose
c1923c5ada Web assembly build with emscripten. 2018-10-16 23:08:26 -04:00
Calvin Rose
e963672977 Make the assembler optional during compilation. 2018-09-29 10:58:57 -04:00
Calvin Rose
c8ef2a0d88 Rename to janet 2018-09-05 22:18:42 -04:00
Calvin Rose
75c66ea6dd Refactor native module declarations. marshal can now
serialize entire environment.
2018-08-26 14:35:01 -04:00
Calvin Rose
84f2c84fb5 Fix tabs in repl. 2018-08-25 15:34:27 -04:00
Calvin Rose
510feeed7f Allow marshaling of more functions for core.
Fix indentation in some files.
2018-08-22 21:41:25 -04:00
Calvin Rose
d95941597f Fix help. 2018-08-15 22:48:35 -04:00
Calvin Rose
48c2654312 Local changes. 2018-08-07 00:54:47 -04:00
Calvin Rose
7a7291ac3a Remove extra code. 2018-08-03 21:51:35 -04:00
Calvin Rose
169a22f03e Fix init.dst, work on metabuild tool to make
native module creation easier
2018-08-03 21:50:32 -04:00
Calvin Rose
5b15ad9ff8 Try and fix os.clock on windows. 2018-07-08 20:54:41 -04:00
Calvin Rose
1f37919f39 Rename boot.dst to core.dst 2018-07-04 00:21:18 -04:00
Calvin Rose
a018f9f54a Major refactor. Move files around, merge compiler into
core and other changes, work on inlining many c functions.
2018-07-03 23:07:35 -04:00
Calvin Rose
e60c8a9b75 Update indentation in boot and init to be more like
most lisps.
2018-07-01 21:12:46 -04:00
Calvin Rose
5afde3f6d4 Add line numbers to repl like irb. 2018-06-29 13:01:23 -04:00
Calvin Rose
bb406133de New sourcemaps v1. 2018-06-28 23:37:04 -04:00
Calvin Rose
5e9d1d07b9 Better refresh after coming back from suspend. 2018-06-24 13:20:32 -04:00
Calvin Rose
ceff49a08d Enable suspending repl with ctrl-z. 2018-06-24 13:18:44 -04:00
bakpakin
1690fee446 Add failure on top level error. 2018-06-08 15:58:23 -04:00
Calvin Rose
8a346ec655 Add option to cli interface to stop scanning options. 2018-05-26 14:17:44 -04:00
Calvin Rose
68895e27d4 Change import semantics. Fix gc bug with fibers. 2018-05-18 20:53:19 -04:00
Calvin Rose
f295692b50 Update copyright to 2018. Add string methods. 2018-05-17 23:41:20 -04:00
Calvin Rose
6ac59251e9 Fix some very mild memory leaks in line.c and the do_bytes function (not
deiniting the parser).
2018-05-15 22:05:47 -04:00
Calvin Rose
c6f79eca6d Make setting up stl easier. Add shared library output to Makefile. 2018-05-14 21:52:51 -04:00
Calvin Rose
dafc121f4d Change c function macros to be explicitly non functional by
capitalizing them.
2018-05-12 20:31:28 -04:00
Calvin Rose
584c75b3f6 Update Makefile for faster builds. 2018-05-10 11:11:18 -04:00
Calvin Rose
932a0324ee More work on renaming functions. Change long string syntax to use
backticks. Allow custom masks in fibers for custom error and debug
handling.
2018-05-09 17:01:58 -04:00
Calvin Rose
f47323c915 Change convention for naming modules and functions. 2018-05-08 19:40:28 -04:00
Calvin Rose
0cd6cdc28b Add some more opcodes for comparison with numeric types. 2018-05-07 12:34:04 -04:00
Calvin Rose
104b09d848 Make the -s option more useful. 2018-05-07 01:04:56 -04:00
Calvin Rose
55f0e759d9 Add extra information in repl to show state of parsing. 2018-05-06 23:25:59 -04:00
bakpakin
d9e5019a71 Add -e option to dst for executing inline scripts from the shell. 2018-05-05 14:05:56 -04:00
Calvin Rose
0d5b57daee Remove exit in favor of os-exit. 2018-03-28 21:24:54 -04:00
Calvin Rose
73ead5c2de Update core namespace. Clean up some code,
and put more emphasis on indexed data-structure combinators
instead of iterators.
2018-03-28 13:58:56 -04:00
Calvin Rose
a3ed7327c9 Make array literals require preceding @ character. 2018-03-24 12:48:42 -04:00
Calvin Rose
e114ec0095 Move web client code. 2018-03-19 17:13:36 -04:00
Calvin Rose
82e5d915f7 Add makefile back. 2018-03-18 09:17:20 -04:00
Calvin Rose
4a76f2ae32 Replace varset! with algol style := 2018-03-16 18:15:34 -04:00
Calvin Rose
72d8e74a71 Update assembly and add example. 2018-03-16 14:34:48 -04:00
Calvin Rose
1ec704feb9 Remove pretty printer implemented in C. 2018-03-14 13:38:48 -04:00
Calvin Rose
d5e4496e95 Change repl prompt. 2018-03-14 10:54:32 -04:00
Calvin Rose
7ec2efcf6d Simple fix for end of file in getline. Some code changes in getline as well. 2018-03-14 10:49:26 -04:00
Calvin Rose
58d81d44f9 Fix windows build 2018-03-13 23:52:27 -04:00
Calvin Rose
c23ea536da Add getline on unix. 2018-03-13 23:39:49 -04:00
Calvin Rose
2b1dd79f55 Work on emscripten support. Works with sync code. 2018-03-13 14:03:17 -04:00
Calvin Rose
3b2658150e Update boot.dst for better functionality (require, macros,
documentation, cond, let, etc.)
2018-03-12 00:26:13 -04:00
Calvin Rose
e047b39a87 More work on self hosting the client program. 2018-02-07 13:19:34 -05:00
Calvin Rose
3e1f031576 Self host the repl, remove linenoise, and selfhost the
main client.
2018-02-07 00:44:51 -05:00
Calvin Rose
ccdf758e83 Get dst to compile on windows 2018-02-01 17:09:22 -08:00
bakpakin
4f74d57359 Refactor stl to corelib and stl. Corelib is part of vm, stl
is part of dst language. Add bootstrapping code directly into stl.
Stl is now logically grouped with compiler.
2018-01-29 23:38:49 -05:00
bakpakin
ce5708af98 Switch over to Cmake fully. 2018-01-29 15:46:26 -05:00
bakpakin
8fe9881187 More work on adding c functions. Added buffer literals again. 2018-01-27 15:15:09 -05:00
bakpakin
30f62ca454 Major refactor and restructure. Add CMake for anticipated windows
support.
2018-01-19 16:43:19 -05:00