Commit Graph

731 Commits

Author SHA1 Message Date
Erik Svedäng
148add054f
Merge pull request #649 from hellerve/veit/reformat-core
Reformat carp_string and carp_byte
2020-01-28 15:24:00 +01:00
Erik Svedäng
60d98a8c15
Merge pull request #648 from hellerve/veit-cleanup-bench
Move get-time-elapsed into Bench module
2020-01-28 15:21:13 +01:00
hellerve
ac73729edf core: better performing Map./Set.put! 2020-01-27 16:58:10 +01:00
hellerve
78cdcb46e7 core: reformat 2020-01-27 16:57:08 +01:00
hellerve
1b7e027642 core: move elapsed_time into bench module 2020-01-27 16:56:22 +01:00
Erik Svedäng
ea045be426 Merge branch 'byte-type' of https://github.com/hellerve/Carp into hellerve-byte-type 2020-01-27 10:10:58 +01:00
Erik Svedäng
4801fec15d Merge branch 'veit/apply-ref' of https://github.com/hellerve/Carp into hellerve-veit/apply-ref 2020-01-27 10:07:50 +01:00
hellerve
95739d0cea core: add IO.getenv 2020-01-25 14:23:14 +01:00
hellerve
3ebe10d587 core: make Maybe.apply take function ref 2020-01-25 14:08:37 +01:00
Erik Svedäng
afea0555b1
Merge pull request #644 from hellerve/reformat-core
core: reformat core.h
2020-01-23 10:15:36 +01:00
Erik Svedäng
773824f5e7 Merge branch 'master' of https://github.com/hellerve/Carp 2020-01-23 10:12:34 +01:00
hellerve
09404798c2 core: add Result.map-error 2020-01-22 12:36:03 +01:00
hellerve
ab5cbb3a49 core: reformat core.h 2020-01-22 12:18:03 +01:00
hellerve
65db2bc2a8 macros: add comp 2020-01-15 16:52:36 +01:00
Erik Svedäng
bd397f8d50
Merge pull request #635 from hellerve/string-from-cstr
core: add String.from-cstr
2020-01-15 09:44:05 +01:00
Erik Svedäng
0ca676f337
Merge pull request #634 from hellerve/make-result-fns-ref
core: make result functions take refs
2020-01-14 10:52:05 +01:00
hellerve
cc6774ef8c core: make String.from-cstr copy 2020-01-14 10:08:29 +01:00
hellerve
3d1abf1469 commands: check char-at 2020-01-14 09:32:22 +01:00
hellerve
cd0c09da3f core: add String.from-cstr 2020-01-13 22:49:23 +01:00
hellerve
40f3975937 core: make result functions take refs 2020-01-13 22:40:20 +01:00
Erik Svedäng
d0f2c447be
Merge pull request #632 from hellerve/fix-array-reduce-example
Fix example in Array.reduce documentation
2020-01-07 10:39:18 +01:00
hellerve
a67c33d2f5 core: fix example in Array.reduce (thanks @Emiluren) 2020-01-06 23:29:49 +01:00
Erik Svedäng
11be440fab Work around defdynamic-once not working inside modules for now. 2019-12-18 12:35:27 +01:00
Erik Svedäng
50d91859c4 Merge branch 'master' of https://github.com/carp-lang/Carp 2019-12-18 12:11:50 +01:00
Erik Svedäng
7c15ec299b 'defined?' and 'defdynamic-once' 2019-12-18 12:10:47 +01:00
Erik Svedäng
2926abd1c8 Got rid of all but one compiler complaints on Windows. 2019-12-18 11:33:42 +01:00
Erik Svedäng
99bf013b81
Merge pull request #626 from nateupstairs/master
[win] attempt to fix windows compilation
2019-11-29 14:15:32 +01:00
Erik Svedäng
a6fb8c2515
Merge pull request #625 from hellerve/map->
RFC: Add Array.unreduce
2019-11-27 10:58:27 +01:00
hellerve
231b0a1d97 macros: fix nthcdr like @scolsen suggested 2019-11-26 07:13:14 +01:00
Erik Svedäng
e850da236f
Merge pull request #622 from hellerve/cxr
macros: add cxr, nthcar, and nthcdr
2019-11-25 12:58:24 +01:00
Erik Svedäng
81776b9635 Merge branch 'master' into hellerve-until 2019-11-25 12:44:14 +01:00
Erik Svedäng
34c314e6fe
Merge pull request #618 from sdilts/fopen-safe
Add open-file function
2019-11-25 12:42:42 +01:00
Erik Svedäng
cf276f4488
Merge pull request #608 from hellerve/pointer-arith
Add pointer arithmetic
2019-11-25 12:36:10 +01:00
hellerve
6bf45e16a6 macros: add until 2019-11-22 13:10:36 +01:00
hellerve
b1b84c8e3a core: rename map-> to unreduce 2019-11-21 11:05:21 +01:00
nateupstairs
539804d9b0 [win] attempt to fix windows compilation 2019-11-20 13:26:59 -08:00
hellerve
48b8b4ec13 core: add Array.map-> 2019-11-13 10:47:22 +01:00
hellerve
bc87e82d9f macros: add cxr, nthcar, and nthcdr 2019-11-09 12:52:11 +01:00
sdilts
5614103107 open-file: Return the value of errno instead of an error string 2019-11-01 17:28:52 -06:00
sdilts
77614b21d9 Add errno to System.carp
+ Error values included are those that can be set from calling `fopen`
+ Change order of imports so that the System module is available before the IO module
2019-11-01 17:26:56 -06:00
sdilts
0386971f00 Add open-file function
`fopen` returns a nullable pointer, which doesn't fit very well with
Carp's notions of saftey and error handling. Instead, return a
`Result` type that forces the user to check if the operation was
successful.
+ Can't call the function fopen because we can't overload a C
  function.
+ Leave `fopen` public in the IO module so extant code doesn't need to
  be changed.
2019-11-01 14:54:18 -06:00
hellerve
98bc275ea5 core: add Byte.hash 2019-11-01 10:52:34 +01:00
hellerve
15c27bdb49 core: allow byte as member type 2019-11-01 10:52:34 +01:00
hellerve
f1f252639f core: add a byte type 2019-11-01 10:52:34 +01:00
Erik Svedäng
16e9418d25
Merge pull request #616 from GrayJack/unsafe_fn
Rename known unsafe function to make clear that they're unsafe
2019-11-01 10:08:42 +01:00
GrayJack
52ce78ab13 Fix wrong parameter usage 2019-11-01 03:19:02 -03:00
GrayJack
d852662002 Added safe version of nth 2019-10-31 19:14:44 -03:00
Erik Svedäng
e90a123274 Merge branch 'includes' of https://github.com/GrayJack/Carp into GrayJack-includes 2019-10-31 14:30:07 +01:00
GrayJack
07def7db23 Fix all nth usage 2019-10-31 06:23:23 -03:00
Erik Svedäng
84afdb2575
Merge pull request #609 from hellerve/clang-format
Add .clang-format
2019-10-31 09:48:15 +01:00