69 Commits

Author SHA1 Message Date
Jason Turner
36208b401e Make the prelude string a bit more manageable 2009-07-07 00:21:19 +00:00
Jonathan Turner
2c5b1323dd Fixed a loss of error location on function calls 2009-07-06 16:27:27 +00:00
Jonathan Turner
0708f32694 Added bool equations to bootstrap 2009-07-06 16:11:03 +00:00
Jonathan Turner
7ceb3e8700 Added concat function 2009-07-06 14:54:12 +00:00
Jonathan Turner
26f5d25243 Bug fix to returning values inside of a loop 2009-07-06 13:01:28 +00:00
Jonathan Turner
494335fb09 Change default push_back behavior 2009-07-04 15:20:15 +00:00
Jonathan Turner
e151e26d60 A minor correction to range vector generation 2009-07-04 13:40:42 +00:00
Jonathan Turner
a76cc16922 Better ranged vector, now generated from a new prelude function 2009-07-04 13:04:55 +00:00
Jonathan Turner
cda30f3ed7 Add range values of the form [x..y], currently internally generatored 2009-07-04 12:33:27 +00:00
Jonathan Turner
4afdee1c09 Add odd and even functions 2009-07-04 10:58:07 +00:00
Jonathan Turner
b2a99d4105 Add modulus operator to parser 2009-07-04 02:17:50 +00:00
Jason Turner
310dd030ac Register string as a container type and update the prelue to guard to_string for ranges against strings. 2009-07-03 16:37:18 +00:00
Jonathan Turner
b191d5a2ee Fix sum and product to start with floating point instead of int 2009-07-03 15:32:58 +00:00
Jonathan Turner
294d22ac5b Remove unnecessary type comparison in equation 2009-07-03 14:52:05 +00:00
Jonathan Turner
34983dbed2 Added take_while and drop_while 2009-07-03 14:08:58 +00:00
Jonathan Turner
f35c2908d7 Change old reduce to foldl. Add clojure reduce. Add sum, product. Add take, drop, filter 2009-07-03 13:09:39 +00:00
Jonathan Turner
9c7f63e8b2 Fixed prefix operator precedence bug. Added collate(?), zip_with, and zip 2009-07-03 12:13:29 +00:00
Jonathan Turner
78be32927c Fixed repl scope leak after an exception 2009-07-03 03:13:05 +00:00
Jonathan Turner
db9442d5a8 More prelim testing to isolate repl issue 2009-07-02 22:54:50 +00:00
Jonathan Turner
af4b1a2bfb Tracking down the 'to_string in repl clobbers vars' issue, not done yet 2009-07-02 21:23:49 +00:00
Jason Turner
47052f710c Fix some semantics of operator= to reduce dispatch, etc.
Also, add more bootstrapping support for some of the built in types.
2009-07-02 19:59:40 +00:00
Jonathan Turner
a70af22eaf Add initial pair printing 2009-07-02 19:26:25 +00:00
Jonathan Turner
441112648e General cleanup to chaiscript prelude 2009-07-02 18:09:02 +00:00
Jonathan Turner
6ddef8f918 Changed to using to_string as dispatch instead of print and puts 2009-07-02 17:45:58 +00:00
Jonathan Turner
60b814f687 Added print and puts for ranged values 2009-07-02 17:39:53 +00:00
Jonathan Turner
6d4f2146b8 Added function guards 2009-07-02 17:22:12 +00:00
Jonathan Turner
f6342ef2a8 Remove stale && and || registration 2009-07-01 20:02:01 +00:00
Jonathan Turner
8e732f3087 Allow more general function dispatch 2009-07-01 19:47:12 +00:00
Jonathan Turner
57c75dae31 Add && and || operator short-circuiting 2009-07-01 17:57:14 +00:00
Jonathan Turner
feb4cc0d14 Fix eval() function 2009-07-01 17:45:48 +00:00
Jonathan Turner
042df442a1 Fixes to for loops. Added elseif and else 2009-07-01 17:13:52 +00:00
Jonathan Turner
27f6ec7b70 Change equation to clone rhs. Add := ref equation. Failed clones will ref copy 2009-07-01 16:48:27 +00:00
Jonathan Turner
5f96b39c08 Allow bash script header 2009-07-01 13:41:15 +00:00
Jonathan Turner
3214f427ff Added for loop 2009-07-01 13:33:29 +00:00
Jonathan Turner
bb174b37a6 Added inline map creation 2009-07-01 13:19:26 +00:00
Jonathan Turner
2cba593c53 Add prefix ++ and -- 2009-06-30 19:34:16 +00:00
Jonathan Turner
e6a0dc9af6 Fix with function definitions of zero params 2009-06-30 19:11:12 +00:00
Jonathan Turner
1bc71d21bd Move parser-specific stuff into its own class 2009-06-30 18:54:33 +00:00
Jonathan Turner
ee44ae0ca0 Initial reworking of chaiscript parser to use the new chaioop parser 2009-06-30 18:17:15 +00:00
Jonathan Turner
ae3ce3fcb2 Fix arity when registering lambdas and functions 2009-06-25 23:14:46 +00:00
Jonathan Turner
96f3033a42 Moved to using a prelude header 2009-06-25 14:16:32 +00:00
Jonathan Turner
18985b6a97 Added puts and join 2009-06-25 02:45:28 +00:00
Jason Turner
eb5dbe4975 Add more specific exception types to the dynamic system and handle them properly 2009-06-25 00:03:23 +00:00
Jonathan Turner
d8b5847ff6 Fix for Issue 38: array push_back 2009-06-24 16:19:25 +00:00
Jonathan Turner
3ed5fe0c97 Added ws skipping. Non ws skipping versions of base parsers. Added comment skipping 2009-06-24 13:53:05 +00:00
Jason Turner
d02620bb1b Cleanup Cast_Helper and add new boxed_cast<>() function. 2009-06-23 02:47:47 +00:00
Jonathan Turner
68da0eb404 Added map and reduce functions 2009-06-22 11:51:56 +00:00
Jason Turner
80ed8eb505 Make EvalError a subclass of runtime_error and provide the std::exception with a robust description for easier debugging of callback/scripted function calls 2009-06-21 20:07:11 +00:00
Jason Turner
786d194689 Handle the ReturnVal exception at the eval_function level so that functions passed back to C++ land have their return values handled properly 2009-06-21 19:45:36 +00:00
Jason Turner
dc11237af9 Add build_functor algorithm for constructing a boost function_object from a script snippet 2009-06-21 18:09:00 +00:00