Update to the last Rust.
This renames lib.rs to nalgebra.rs so that the generated *.so has the right name.
This commit is contained in:
parent
1e71dc1d0a
commit
f83ddde824
8
Makefile
8
Makefile
|
@ -3,20 +3,20 @@ nalgebra_lib_path=lib
|
|||
nalgebra_doc_path=doc
|
||||
all:
|
||||
mkdir -p $(nalgebra_lib_path)
|
||||
rustc src/lib.rs --out-dir $(nalgebra_lib_path) --opt-level 3
|
||||
rustc src/nalgebra.rs --out-dir $(nalgebra_lib_path) --opt-level 3
|
||||
|
||||
test:
|
||||
mkdir -p $(nalgebra_lib_path)
|
||||
rustc --test src/lib.rs --opt-level 3 -o test~ && ./test~
|
||||
rustc --test src/nalgebra.rs --opt-level 3 -o test~ && ./test~
|
||||
rm test~
|
||||
|
||||
bench:
|
||||
rustc --test src/lib.rs --opt-level 3 -o bench~ && ./bench~ --bench
|
||||
rustc --test src/nalgebra.rs --opt-level 3 -o bench~ && ./bench~ --bench
|
||||
rm bench~
|
||||
|
||||
doc:
|
||||
mkdir -p $(nalgebra_doc_path)
|
||||
rustdoc src/lib.rs
|
||||
rustdoc src/nalgebra.rs
|
||||
|
||||
distcheck:
|
||||
rm -rf $(tmp)
|
||||
|
|
|
@ -18,13 +18,13 @@ macro_rules! at_fast_impl(
|
|||
($t: ident, $dim: expr) => (
|
||||
impl<N: Clone> $t<N> {
|
||||
#[inline]
|
||||
unsafe fn at_fast(&self, (i, j): (uint, uint)) -> N {
|
||||
pub unsafe fn at_fast(&self, (i, j): (uint, uint)) -> N {
|
||||
(*cast::transmute::<&$t<N>, &[N, ..$dim * $dim]>(self)
|
||||
.unsafe_ref(i + j * $dim)).clone()
|
||||
}
|
||||
|
||||
#[inline]
|
||||
unsafe fn set_fast(&mut self, (i, j): (uint, uint), val: N) {
|
||||
pub unsafe fn set_fast(&mut self, (i, j): (uint, uint), val: N) {
|
||||
(*cast::transmute::<&mut $t<N>, &mut [N, ..$dim * $dim]>(self)
|
||||
.unsafe_mut_ref(i + j * $dim)) = val
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue