Tim Chevalier
503dec1d62
Further WIP on classes
...
Changes to resolve and typeck. Still nothning working yet.
2012-02-09 14:36:43 -08:00
Brian Anderson
9effae8413
Merge pull request #1794 from matricks/bugfix
...
fixed memmove. were using memcpy due to copy paste error
2012-02-09 13:47:55 -08:00
Brian Anderson
1ccbba3341
cargo: Disable system mode per discussion on #1760
2012-02-09 13:42:59 -08:00
Magnus Auvinen
a422cd7ddb
fixed memmove. were using memcpy due to copy paste error
2012-02-09 21:47:12 +01:00
Tycho Sci
d846169b15
cargo: 2 modes -> 3 modes, and clarify them
...
* -g or --mode=user to create/use .cargo under $HOME
* -G or --mode=system to create/use .cargo under sysroot
* by default, `cargo` uses .cargo under current working directory
2012-02-09 12:15:30 -08:00
Tycho Sci
48e206ee81
cargo: Add local mode and use it by default
2012-02-09 12:15:30 -08:00
Marijn Haverbeke
0b4851cff6
Fix bug in decoding of method metadata
2012-02-09 17:08:54 +01:00
Marijn Haverbeke
02082be4a7
Fix various bugs in monomorphization
...
Enough to be able to compile librustc with --monomorphize.
Issue #1736
2012-02-09 15:30:48 +01:00
Marijn Haverbeke
52a741754c
Remove some pointless imports
2012-02-09 15:30:27 +01:00
Marijn Haverbeke
50fb4c30ed
Increase precedence of as operator
...
Closes #1717
2012-02-09 11:58:08 +01:00
Marijn Haverbeke
1dc5e1aa94
Monomorphize methods and bounded parameters
...
Issue #1736
2012-02-09 11:58:07 +01:00
Brian Anderson
149d1d4a6e
core: Add a test for blocking in native code
2012-02-08 15:42:51 -08:00
Brian Anderson
35ba9715fa
core: Add task::spawn_sched
...
This function creates a new scheduler with a specified number of threads and
immediately executes a task on it. The scheduler is configured to terminate
when the task dies. This is the minimum API necessary to enable blocking C
calls.
2012-02-08 15:42:51 -08:00
Brian Anderson
2f4e7c157e
rt: Export a scheduler API
2012-02-08 15:42:51 -08:00
Brian Anderson
f2a1aa2649
rt: Hold schedulers in a map
2012-02-08 15:42:51 -08:00
Brian Anderson
028af5cb6c
rt: Change the lifecycle of tasks and schedulers for various reasons
...
This is in preparation for giving schedulers their own life cycle separate
from the kernel.
Tasks must be deleted before their scheduler thread, so we can't let the
scheduler exit before all its tasks have been cleaned up. In this scheme,
the scheduler will unregister tasks with the kernel when they are reaped,
then drop their ref on the task (there may still be others). When the task
ref count hits zero, the task will request to be unregistered from the
scheduler, which is responsible for deleting the task.
Instead of having the kernel tell the scheduler to exit, let the scheduler
decide when to exit. For now it will exit when all of its tasks are
unregistered.
2012-02-08 15:42:51 -08:00
Brian Anderson
ebc3646c39
rt: Start schedulers immediately upon creation
2012-02-08 15:42:51 -08:00
Brian Anderson
7685e5de94
rt: Refactor the rust_kernel interface a bit
2012-02-08 15:42:47 -08:00
Brian Anderson
ad80823a6c
rt: Introduce scheduler ids
2012-02-08 15:33:40 -08:00
Brian Anderson
c76b81cddf
rt: Delete schedulers immediately upon release
...
This will be needed once we support dynamically changing schedulers.
2012-02-08 15:33:40 -08:00
Brian Anderson
f39e64d56a
rt: Change the scheme used for terminating the kernel
...
Instead of joining on the scheduler threads, instead keep a count of active
schedulers. When there are no more schedulers raise a signal for the main
thread to continue.
This will be required once schedulers can be added and removed from the
running kernel.
2012-02-08 15:33:40 -08:00
Brian Anderson
6eafe5d772
rt: Remove is_running flag from rust_thread. Unused
2012-02-08 15:33:40 -08:00
Brian Anderson
fad3de5900
rt: Remove rust_scheduler::rval. Unused
2012-02-08 15:33:40 -08:00
Tim Chevalier
48769b57e0
A bit more WIP on classes, and some cleanup in resolve
2012-02-08 15:21:45 -08:00
Niko Matsakis
6e680e36a7
deprecate old style box shape strings
2012-02-08 13:10:20 -08:00
Niko Matsakis
a6dde7766e
fix bug that causes premature pops from obstack
...
basically, the alignment step did not check if it walked off
the end of the buffer
2012-02-08 12:55:19 -08:00
Brian Anderson
5f8e0ddccf
Merge pull request #1783 from erickt/master
...
Adding a str::as_bytes<T>(str, fn([u8] -> T) -> T function
2012-02-08 11:22:07 -08:00
Erick Tryzelaar
3a413aabd4
core: add str::as_bytes function
...
This pattern is used in a couple places, so it'd be nice
to abstract it away.
2012-02-08 10:18:36 -08:00
Niko Matsakis
526e73d7f8
make shape code use the tydesc found in the box, not the shape str
2012-02-08 09:14:59 -08:00
Graydon Hoare
3a1e33e134
Register new snapshots.
2012-02-08 07:58:42 -08:00
Marijn Haverbeke
8ffd6e4e8a
Suppress warnings in compiletest
2012-02-08 10:45:50 +01:00
Marijn Haverbeke
0547d0cc5b
Monomorphize resource and variant constructors
...
Issue #1736
2012-02-08 10:45:50 +01:00
Brian Anderson
7c8d128e1f
bench: Add shootout-spectralnorm
2012-02-08 01:06:16 -08:00
Brian Anderson
708f7b927c
core: Export floor functions
2012-02-07 22:02:55 -08:00
Brian Anderson
9b01620e8d
rt: Don't ignore result of chdir. Fail hard for now with a FIXME
...
My gcc won't let the result of this function be ignored.
2012-02-07 20:28:57 -08:00
Brian Anderson
6cf40bd0c4
std: Use correct split function in generic_os::env
2012-02-07 20:20:58 -08:00
Graydon Hoare
93450abb4b
Make process-spawning take environments and working directories, remove procsrv task from compiletest.
2012-02-07 19:57:03 -08:00
Tim Chevalier
5131216fa6
Restore a comment that got lost (comments only)
2012-02-07 17:08:03 -08:00
Brian Anderson
0c13ee22ad
core: Use substr in extfmt instead of slice_bytes
2012-02-07 16:34:02 -08:00
Kevin Cantu
1aa23947a6
core: add str::splitn_char and fix str::splitn_char_iter
2012-02-07 16:25:35 -08:00
Kevin Cantu
2b0396c34a
core: make str::substr use char positions (and replace other uses)
2012-02-07 16:25:35 -08:00
Kevin Cantu
a3f5626ad1
String split renaming:
...
* Renamed str::split -> str::split_byte
* Renamed str::splitn -> str::splitn_byte
* Renamed str::split_func -> str::split
* Renamed str::split_char -> str::split_char
* Renamed str::split_chars_iter -> str::split_char_iter
* Added u8::is_ascii
* Fixed the behavior of str::split_str, so that it matches split_chars
and split (i.e. ["", "XXX", "YYY", ""] == split_str(".XXX.YYY.", "."))
* Fixed str::split_byte and str::splitn_byte so that they handle
splitting UTF-8 strings on a given UTF-8/ASCII byte and also handle ""
as the others do
2012-02-07 16:25:35 -08:00
Brian Anderson
159aebc28b
core: Whitespace policia
2012-02-07 15:08:54 -08:00
Brian Anderson
45bcef78e3
Add Magnus Auvinen to AUTHORS.txt
2012-02-07 15:08:54 -08:00
Magnus Auvinen
a5fc0b08de
added some documentation and made the memcpy and memmove unsafe
2012-02-07 15:08:54 -08:00
Magnus Auvinen
3e9859362b
made leak an intrinsic to avoid a c-call. added memmove and memcpy intrinsics
2012-02-07 15:08:54 -08:00
Tim Chevalier
a63780afce
Minor class-related tweaks to the AST
2012-02-07 12:15:59 -08:00
Marijn Haverbeke
47143ee24a
Stop storing cmp glue in tydescs
...
There's no such thing anymore, we can simply call upcalls.cmp_type.
2012-02-07 14:37:10 +01:00
Marijn Haverbeke
b28a5552e3
Reuse monomorphized functions for different box types
...
The free glue for opaque boxes will pick the actual tydesc out of the
box, and call its glue.
Issue #1736
2012-02-07 14:36:02 +01:00
Brian Anderson
3bd0338c19
Revert "log to stderr instead of stdout"
...
This is causing mysterious hangs on windows. Issue #1769 .
This reverts commit d65eabd5de
.
2012-02-06 18:29:58 -08:00