Commit graph

155 commits

Author SHA1 Message Date
Gwenhael Le Moine
f4fa29da5c
parser understands lists 2022-02-17 15:14:20 +01:00
Gwenhael Le Moine
7fce85d694
switch from test-unit to minitest 2022-02-17 15:09:29 +01:00
Gwenhael Le Moine
9480c49272
up version to 0.2.0 2022-02-16 16:29:28 +01:00
Gwenhael Le Moine
e143ef2a29
helper Makefile 2022-02-16 16:29:18 +01:00
Gwenhael Le Moine
e9a269e652
[bin/rpl] implicit -i if no args given 2022-02-16 16:28:33 +01:00
Gwenhael Le Moine
dc5159cf11
Merge branch 'trunk' of ssh://src.le-moine.org:38172/gwh/rpl.rb into trunk 2022-02-16 16:25:14 +01:00
Gwenhael Le Moine
e529b19f12
bin/rpl can load files, run code, optionally start a REPL and print stack's content on exit 2022-02-16 16:23:37 +01:00
Gwenhael Le Moine
f74a8d8e45
allow making REPL using preloaded interpreter 2022-02-16 16:22:52 +01:00
Gwenhael Le Moine
603a1627df
RPL's lists are enclosed in {} 2022-02-16 16:21:37 +01:00
Gwenhael Le Moine
5a53b960b4
fix gemspec required_ruby_version 2022-02-15 18:54:54 +01:00
Gwenhael Le Moine
42244c7106
Merge branch 'trunk' of ssh://src.le-moine.org:38172/gwh/rpl.rb into trunk 2022-02-15 18:48:27 +01:00
Gwenhael Le Moine
df32808ae0
xpon 2022-02-15 18:48:19 +01:00
Gwenhael Le Moine
8b07724e50
make it a gem 2022-02-15 17:06:19 +01:00
Gwenhael Le Moine
c4e5356467
define RplRepl only if called directly 2022-02-15 13:18:01 +01:00
Gwenhael Le Moine
0b125b6b53
[repl] completion based on dictionary's words and vars 2022-02-15 11:15:16 +01:00
Gwenhael Le Moine
fece818539
dangling lines 2022-02-15 11:15:10 +01:00
Gwenhael Le Moine
817823be0d
rpl.rb +x 2022-02-15 11:09:39 +01:00
Gwenhael Le Moine
8f1f871904
continue to prepare implementation 2022-02-11 16:30:49 +01:00
Gwenhael Le Moine
a704d57a4f
prepare implementation 2022-02-11 16:15:38 +01:00
Gwenhael Le Moine
2eb8fa91ef
logs → logarithm 2022-02-11 16:15:01 +01:00
Gwenhael Le Moine
0f09f57f5d
change semantic of TIMES and LOOP 2022-02-11 16:06:57 +01:00
Gwenhael Le Moine
2d94127444
refactoring, make comment active documentation 2022-02-11 15:46:47 +01:00
Gwenhael Le Moine
c2043ba663
merge REPL in main file rpl.rb 2022-02-10 18:38:38 +01:00
Gwenhael Le Moine
80fbf082b2
fix stack_extract 2022-02-10 18:37:44 +01:00
Gwenhael Le Moine
e9e44f7d69
extracting from stack in 2 steps to leave stack intact in case of error 2022-02-10 14:57:14 +01:00
Gwenhael Le Moine
b8724a4a1c
refactoring: split interpreter 2022-02-10 14:50:59 +01:00
Gwenhael Le Moine
3ebec3e4b0
biggest refactoring, OOP 2022-02-10 14:33:09 +01:00
Gwenhael Le Moine
a148d73a5e
document all remaining (implemented) words 2022-02-10 09:54:24 +01:00
Gwenhael Le Moine
5fcf628705
[wip] document more words; meh 2022-02-09 16:59:51 +01:00
Gwenhael Le Moine
195ebb37b7
implement HELP 2022-02-09 16:38:09 +01:00
Gwenhael Le Moine
912ca03f9c
implement BREAK 2022-02-09 16:37:46 +01:00
Gwenhael Le Moine
282ab3b239
TODO 2022-02-09 16:37:32 +01:00
Gwenhael Le Moine
9ab26ef85e
naming & kludge 2022-02-09 16:37:18 +01:00
Gwenhael Le Moine
6e77c313b2
implement VERSION and UNAME 2022-02-09 16:35:54 +01:00
Gwenhael Le Moine
717e04549e
test core.stringify 2022-02-09 16:35:17 +01:00
Gwenhael Le Moine
7d1a91705b
indentation 2022-02-09 16:35:11 +01:00
Gwenhael Le Moine
d00a6e8ac7
grammar 2022-02-09 16:34:12 +01:00
Gwenhael Le Moine
9ebdb707c5
parser a static method of Interpreter 2022-02-09 16:33:47 +01:00
Gwenhael Le Moine
6982deaefc
x/0 = ∞ 2022-02-09 16:31:24 +01:00
Gwenhael Le Moine
b98a97b6b8
all :numerics need to be BigDecimal 2022-02-09 16:29:01 +01:00
Gwenhael Le Moine
922ecf1bb6
stringify infinites and NaN 2022-02-09 16:28:35 +01:00
Gwenhael Le Moine
4413146f52
version 0.1 2022-02-09 16:28:07 +01:00
Gwenhael Le Moine
6dae5e3eb0
refactoring: inline parser & runner into Interpreter 2022-02-09 13:38:32 +01:00
Gwenhael Le Moine
3158851685
finally pass d→r test 2022-02-09 10:58:13 +01:00
Gwenhael Le Moine
36283d6d4b
generalize use of BigDecimal in :numeric's 2022-02-09 10:53:00 +01:00
Gwenhael Le Moine
8c5657db42
big refactoring 2022-02-08 15:45:36 +01:00
Gwenhael Le Moine
217a4e98ee
todo 2022-02-02 16:54:25 +01:00
Gwenhael Le Moine
96868a742f
add BigDecimal todo 2022-02-02 16:42:19 +01:00
Gwenhael Le Moine
a512979e91
simplify D→R and R→D, fix R→D test 2022-02-02 16:29:23 +01:00
Gwenhael Le Moine
77946e56f7
fix ACOS and pass some tests (still fragile) 2022-02-02 16:15:44 +01:00