Commit Graph

247 Commits

Author SHA1 Message Date
64eccdd9be Reorganize tests and benchmark scripts.
Mainly to get rid of one top level directory. But this will
also be useful when there are tests of the embedding API.
2015-03-14 12:45:56 -07:00
5459993857 Add Class.supertype.
Thanks, Michel!
2015-03-14 09:48:45 -07:00
69567c5eb5 Control string representation of infinity. 2015-03-13 07:35:10 -07:00
b36b71d3c6 Merge pull request #212 from soveran/io-read-eof
Change IO.read to return null on EOF
2015-03-07 13:47:07 -08:00
05ba7d9fbf Add fiber features needed for to write an external scheduler:
- Allow yielding the main fiber. This exits the interpreter. The
  host can resume it by calling a method.
- Allow getting a reference to the current fiber.
2015-03-07 12:32:11 -08:00
542a783cb4 Change IO.read to return null on EOF 2015-03-07 09:10:18 +00:00
632a01d584 Merge branch 'num_methods' of git://github.com/MarcoLizza/wren into MarcoLizza-num_methods 2015-03-06 22:43:02 -08:00
d35e3c917c Add count to Sequence. 2015-03-06 07:01:02 -08:00
d56e2d6398 Removing old tests. 2015-03-05 11:27:56 +01:00
130d0df957 Fixing the test a bit. 2015-03-05 11:24:54 +01:00
fde6f74d15 Adding tests. 2015-03-04 16:12:08 +01:00
90aa43450b Merge branch 'master' of git://github.com/bjorn/wren into bjorn-master 2015-03-03 07:23:47 -08:00
28005ed47a Refactor number parsing a bit. 2015-03-03 07:17:56 -08:00
0ec31433c8 Generate an error if a number literal is too large to be represented with the Num class. 2015-03-03 00:07:55 -08:00
8f985847d4 Added Sequence.any as complement to Sequence.all 2015-03-01 23:14:32 +01:00
c27a094882 Reorganize superclass validation a bit. 2015-02-27 08:08:27 -08:00
46713a5bb3 Merge branch 'issue-70' of git://github.com/verpeteren/wren into verpeteren-issue-70 2015-02-27 07:41:25 -08:00
96ceaa528b Allow empty argument list methods.
- Compile them as calls and definitions.
- Use them for call(), clear(), run(), try(), and yield().
- Update the docs.
2015-02-26 23:08:36 -08:00
1aaa8cff52 Use more comprehensive signature strings for methods. 2015-02-26 21:56:15 -08:00
f05d6143f5 Generating a runtime error on subclassing of builtins
As discussed in https://github.com/munificent/wren/issues/70, it is not allowed to subclass built-in types.
2015-02-25 20:13:37 +01:00
6a10d9740c Merge pull request #187 from MarcoLizza/bitwise_precedence
Bitwise precedence
2015-02-25 07:14:31 -08:00
fc2ed6f6e1 Don't allow trailing non-number characters when parsing a string to a number. 2015-02-25 07:07:54 -08:00
cec1f9160a Moving bitwise precedence-test to the correct folder. 2015-02-25 16:00:53 +01:00
f4a39bc943 Code review changes. 2015-02-25 01:20:53 -08:00
dfa1b51663 Add bitwise operators precedence test. 2015-02-23 17:29:31 +01:00
03a5b96040 Add a fromString static method on Num that converts strings to numbers. 2015-02-22 20:06:17 -08:00
0f9e15833f Unify argument parsing. Fix #24. 2015-02-22 10:42:49 -08:00
ae88ee539d Merge branch 'master' of https://github.com/munificent/wren 2015-02-18 07:55:38 -08:00
b2ca4c0381 Allow zero or multiple imported names. 2015-02-17 07:32:33 -08:00
00cdef303c Adding new bitwise operands tests. 2015-02-16 11:30:15 +01:00
a44d479643 Basic import syntax. 2015-02-14 16:46:00 -08:00
bc5a793c41 Split out the core and main modules.
- Implicitly import everything in core into every imported module.
- Test cyclic imports.
2015-02-11 10:06:45 -08:00
2005e1e0a2 Add ".wren" to modules in the embedder. 2015-02-06 11:52:05 -08:00
bb647d4247 Start getting module loading working.
Right now, it uses a weird "import_" method on String which
should either be replaced or at least hidden behind some syntax.

But it does roughly the right thing. Still lots of corner cases to
clean up and stuff to fix. In particular:

- Need to handle compilation errors in imported modules.
- Need to implicitly import all core and IO types into imported module.
- Need to handle circular imports.
  (Just need to give entry module the right name for this to work.)
2015-02-06 07:01:15 -08:00
55caae343b Add "." to comments. :) 2015-02-04 20:26:29 -08:00
ddd20c687e Merge branch 'master' into MarcoLizza-8_bit_strings_tests 2015-02-04 20:25:12 -08:00
878be6fb6b Clean up wrenStringFind() a bit. 2015-02-04 20:23:50 -08:00
d73b19967d Adding 8-bit strings test cases. 2015-02-04 13:58:16 +01:00
0aa4d7c2bd Fix crash when doing a lookup on an empty map. 2015-01-28 19:19:04 -08:00
f482a53d0e Define equality on ranges. 2015-01-25 19:50:54 -08:00
41d9ba9b3d Merge branch 'hex-literals' of git://github.com/gsmaverick/wren into gsmaverick-hex-literals 2015-01-25 17:49:05 -08:00
4579171afa Add remove() to Map. 2015-01-25 17:42:36 -08:00
0ad7a7d9ff Code review changes. 2015-01-25 13:02:44 -08:00
0e6a90443e Add containsKey() to Map, and validate key types. 2015-01-25 12:39:19 -08:00
492c730e6f Key and value iteration for maps. Also toString. 2015-01-25 10:27:38 -08:00
251b623c65 Map "clear" method. 2015-01-25 08:39:44 -08:00
e740a4c95a Map literals! 2015-01-24 23:21:50 -08:00
abe80e6d4b Initial map implementation.
Still lots of methods missing and clean up and tests to do.
Also still no literal syntax.

But the core hash table code is there and working. The supported
key types are all, uh, supported.
2015-01-24 22:27:35 -08:00
12102b19ef Adds support for hexadecimal literals. 2015-01-24 22:07:46 -08:00
cff08f989b Rename a couple of tests. 2015-01-24 14:42:25 -08:00