Commit Graph

8385 Commits

Author SHA1 Message Date
Kevin Atkinson
35a199c036 Formatting cleanups. 2012-02-03 20:41:49 -07:00
Kevin Atkinson
9090a5c03b Store info about file "substr".
That is when a string that is part of a file needs to be parsed for a
reason, record that the string is a substr of the file rather than
using "<anon>" or "-" as the file name.  This will eventually allow
pointing to the right location, for now it just uses a more
meaningful string for the filename.
2012-02-03 20:41:49 -07:00
Kevin Atkinson
4d71285c93 Implement quasi-quotes in more macro form: #ast{...}.
The #(...) form is still supported for now.
2012-02-03 20:41:49 -07:00
Kevin Atkinson
1c91fb4d91 Don't rely on filename to get a file from the filemap
as there may be more than one filemap with the same filename (in the
case of stdin for instance).  This involved storing a pointer to the
filemap rather than the filename in location info such as
codemap::pos.
2012-02-03 20:41:49 -07:00
Kevin Atkinson
4616117f17 Bug fix in lookup_byte_offset. 2012-02-03 20:41:49 -07:00
Kevin Atkinson
da74a7f9ca Make macro arg optional in syntax, again untested. 2012-02-03 20:41:48 -07:00
Kevin Atkinson
5ea04c65c1 Add support for recognizing macro body, completely untested. 2012-02-03 20:41:48 -07:00
Kevin Atkinson
e76fdeb3a6 Change the type for the macro body to also store the span.
Note: the body is the part of the macro syntax between the {}.
2012-02-03 20:41:48 -07:00
Kevin Atkinson
099290bc73 When replacing $(...) with $0 preserve spacing for better error messages.
That is:
  x + $(foo) + y
becomes:
  x + $0     + y
not:
  x + $0 + y
2012-02-03 20:41:37 -07:00
Kevin Atkinson
c0f9073557 Expand result of quasi-quote. 2012-02-03 20:39:00 -07:00
Kevin Atkinson
67e961c17f Implement anti-quotes. 2012-02-03 20:38:44 -07:00
Kevin Atkinson
477714f08e Implement "replace" function. 2012-02-03 20:28:12 -07:00
Kevin Atkinson
485e489ba2 Implement basic quasi-quoter. No anti-quotes yet. 2012-02-03 20:28:11 -07:00
Kevin Atkinson
98450d0dad Rename AST builders to use uniform naming scheme. Also add a few more. 2012-02-03 20:28:11 -07:00
Kevin Atkinson
5ef53382ae Add support for parsing quasi-quotes, doesn't do anything useful yet. 2012-02-03 20:23:49 -07:00
Kevin Atkinson
75edd9ff69 Move useful ast building functions into their own module. 2012-02-03 17:48:17 -08:00
Kevin Atkinson
9dcb674525 Add function to get a code snippet from a span,
and also to get the byte offset within a string from a span chpos.
2012-02-03 17:48:17 -08:00
Kevin Atkinson
e127bf680f Fix byte_len in char_len_range to be what it is advertised. 2012-02-03 17:48:16 -08:00
Niko Matsakis
33f4a98388 correct to use enum keyword 2012-02-03 13:58:50 -08:00
Marijn Haverbeke
61367e3c27 Fix prefixing of logging paths with crate name 2012-02-03 22:12:09 +01:00
Brian Anderson
a57c15bf88 rustdoc: Add various sorting passes 2012-02-03 12:00:49 -08:00
Marijn Haverbeke
c976b7c623 Fix tests for str::le patch 2012-02-03 14:32:23 +01:00
Tom Lee
31b0d1b4bd core: rename str::lteq to str::le 2012-02-03 14:09:44 +01:00
Marijn Haverbeke
633e4502e7 Clean up and update trans::ty_ctxt type definition
It had been messed up by the pretty-printer at some point, and was
partially out of date.
2012-02-03 14:09:16 +01:00
Marijn Haverbeke
3bcd4fe6fa Start on in-crate monomorphizing
Adds a --monomorpize flag to rustc to turn it on. You probably don't
want to use it yet, since it's broken in a whole bunch of ways, but it
successfully monomorphizes simple generic functions called from within
the crate.

Issue #1736
2012-02-03 14:07:35 +01:00
Tom Lee
a02f332602 std: rename sort::lteq to sort::le. 2012-02-03 12:02:57 +01:00
Marijn Haverbeke
43ce38375d Store item paths in ast_map, get rid of trans::local_ctxt
The direct motivation for this was that the monomorphizer needs to be
able to generate sane symbols for random items. The typechecker can
probably also use this in the future to provide more useful error
messages.
2012-02-03 11:34:12 +01:00
Marijn Haverbeke
c1b075d042 Remove experimental GC code
It's been sitting unused long enough to have bitrotted completely.
2012-02-03 11:34:12 +01:00
Brian Anderson
1ea184285e rt: Change the win32 event object to an auto-reset event
The way I read the docs, having this be a manual reset event means
that after the first time it's signalled it stays that way until reset,
and we never, ever reset it.
2012-02-02 18:30:06 -08:00
Brian Anderson
3b4dd26ff1 rt: Remove lock_and_signal::signal_all 2012-02-02 18:29:03 -08:00
Brian Anderson
9c33f2c561 rt: Remove lock_and_signal::timed_wait 2012-02-02 18:25:49 -08:00
Brian Anderson
cd774fc5fa rt: Stop waking up the scheduler on a timer 2012-02-02 18:23:01 -08:00
Brian Anderson
b1a090c7c4 rt: Remove unused arguments in rust_scheduler 2012-02-02 18:17:33 -08:00
Brian Anderson
6c632c71c6 rt: Simplify reap_dead_tasks 2012-02-02 18:10:24 -08:00
Brian Anderson
f719ea552b rt: Remove rust_scheduler::interrupt_flag. Unused 2012-02-02 18:10:24 -08:00
Brian Anderson
aee83d2ff1 rt: Only wake up all schedulers when no tasks are left
At the moment there's not really any reason to be raising this signal,
since they schedulers wake up periodically anyway, but once we remove
the timer this will be how the schedulers know to exit.
2012-02-02 18:10:24 -08:00
Brian Anderson
5c3c8d454d rt: Do all signalling while holding a lock
This will matter once the scheduler is changed to not wake up on a timer
2012-02-02 18:10:24 -08:00
Brian Anderson
5449b886d3 rt: Remove bogus task reaping from the scheduler 2012-02-02 18:10:24 -08:00
Brian Anderson
3978fbff8b rt: Remove rust_task::can_schedule. Does nothing 2012-02-02 18:10:24 -08:00
Brian Anderson
ed3a5ad5ad rt: Remove running_on flag. Does nothing 2012-02-02 18:10:24 -08:00
Brian Anderson
57cad61353 rt: Remove task pinning. Does nothing 2012-02-02 18:10:24 -08:00
Brian Anderson
18de0f2aeb rt: Rename task_sleep intrinsic to task_yield. Remove usec param 2012-02-02 18:10:24 -08:00
Brian Anderson
8693fcc2d7 rt: Remove yield timers 2012-02-02 18:10:24 -08:00
Brian Anderson
7f2980b749 rt: Remove bitrotted tests 2012-02-02 18:10:24 -08:00
Brian Anderson
65f4b0587a rt: Generate intrinsics 2012-02-02 18:10:23 -08:00
Brian Anderson
bda40e2e4a rt: Fix intrinsics bustage
intrinsics.cpp and the file to generate the ll had bitrotted.
2012-02-02 18:10:23 -08:00
Graydon Hoare
c485301d21 Update libuv. 2012-02-02 17:39:47 -08:00
Graydon Hoare
6784b18303 Win32 warning police. 2012-02-02 11:35:07 -08:00
Marijn Haverbeke
6a7de641da Add test case for issue #1733 2012-02-02 10:30:07 +01:00
Marijn Haverbeke
743c62e1ce Fix assumption in mut.rs that op overloading breaks
Closes #1733
2012-02-02 08:11:20 +01:00