greg
|
d7181afa91
|
Few more linefeed-related changes
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
4eb7683f47
|
Move linefeed reader to struct
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
b04a8f0092
|
Add back interpreter directives
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
c50be58cd2
|
Moved from simplerepl to lineread crate
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
5911a07f4f
|
Inline parsing of lambdas like half-works
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
26bc6e90f3
|
Lamba calls partially work
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
b0655d7cab
|
need to flush stdout for printing
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
a46ede9395
|
Made evaluation-printing more sophisticated
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
d9ab5a58cf
|
Add some methods to llvm_wrap
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
77297c7e06
|
Add lambdas
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
d93b5c0a2e
|
Still cranking away at conditional compilation
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
0b9dc113d1
|
CLoser to working now
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
d6fc13f08d
|
Fix a couple of problems
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
825c271b17
|
More work on codegen for conditionals
Still doesn't compile
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
8c4f7e141a
|
Compiling if statements like half done
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
12fbc51da1
|
Compile multi-expression source programs
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
7ddb421ced
|
Exit cleanly on opt parse fail
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
1631bb0a04
|
Fix tests for conditionals
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
5923cc2317
|
Kill then, else keywords
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
1fa56800c5
|
Convert parsing while, if, fn exprs to use { }
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
2b4d3e8516
|
Add support for curly braces and brackets
Gonna make this a curly-brace language, I like those better. Shoulda
done that to begin with.
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
9b74527618
|
Control printing eval steps with flags
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
d23e5bff35
|
Add an Op type for binop operators
Soon this will get swapped in as the way that BinOps are evaluated
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
3a4f5ae840
|
Change name Op -> OpTok
So that I can make an Op type for the ASTNode
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
298194c42d
|
Finish support for assignment operators
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
23d2209d8b
|
Implementing a few more operators
WIP - not done
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
4cf165b408
|
Use buffered reader for stdout
Not sure ifthis is actually helping
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
154839979b
|
Add nicer handle_builtin method
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
538f0b18f4
|
Evaluate while loop
|
2017-09-19 22:10:59 -07:00 |
|
greg
|
dc81d237c5
|
Reduce re-allocations in eval
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
8651839a66
|
Getting rid of some newlines - concision
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
f6e5ea250d
|
Convert while_expr to delimiter_block! too
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
9801f53a17
|
Moved conditionals to delimiter_block! syntax
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
db92292569
|
Fixed all tests
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
e1ce54aece
|
Add delimiter_block macro
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
c227ad656f
|
Parser simplifications, renames, etc.
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
b45d09e81a
|
Don't need this reference
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
761500b9d6
|
Some cleanups in Parser
-get rid of some use statements
-mkae error messages better
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
e888e82404
|
Remove some unnecessary destructurings of Rc<String>
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
328ec4ba87
|
Convertd like half the Strings to RC
-still need to eliminate some clones in eval, parse
+ fix all the tests
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
4a7b570603
|
Parser changes - add precedences, move definitions
Move impls of Display for AST subtypes closer to where they are defined
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
7eb48fb4ef
|
Working on compilation again
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
8ebf1b3056
|
Add parser support for while statements
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
905431b33c
|
Change name: ASTNode -> Statement
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
2996198eff
|
lookup_binding only needs &str
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
06771979df
|
Function bodies can contain statements now
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
f158b6c712
|
Converted to multiple-evaluator logic
Now I have (basically) full single-step evaluation and it works fine
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
ba8f67441f
|
Conditionals - handle delimiters correctly
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
872e9ce7ee
|
Make function binding a SideEffect
|
2017-09-19 22:10:58 -07:00 |
|
greg
|
edf342e65a
|
Add == operator
|
2017-09-19 22:10:58 -07:00 |
|