Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected internal compiler error fixing Any #16

Closed
milibopp opened this issue Mar 7, 2014 · 1 comment
Closed

Unexpected internal compiler error fixing Any #16

milibopp opened this issue Mar 7, 2014 · 1 comment

Comments

@milibopp
Copy link

milibopp commented Mar 7, 2014

I just tried fixing the absence of Any from the prelude in the latest Rust compiler like so:

diff --git a/src/object.rs b/src/object.rs
index b76bcbf..3c2dd60 100644
--- a/src/object.rs
+++ b/src/object.rs
@@ -2,6 +2,7 @@

 use std::cell::RefCell;
 use std::rc::Rc;
+use std::any::Any;
 use gl::types::*;
 use nalgebra::na::{Mat3, Vec2, Vec3, Iso3, Rotation, Rotate, Translation, Transformation};
 use nalgebra::na;

This caused an unexpected compiler error:

error: internal compiler error: unexpected failure
This message reflects a bug in the Rust compiler. 
We would appreciate a bug report: http://static.rust-lang.org/doc/master/complement-bugreport.html
note: the compiler hit an unexpected failure path. this is a bug
Ok(task 'rustc' failed at 'index out of bounds: the len is 0 but the index is 0', /build/rust-git/src/rust/src/librustc/lib.rs:1
)

Will report upstream as well, but I thought raising an issue here is probably also a good idea, since it effectively makes compiling kiss3d impossible.

@sebcrozet
Copy link
Owner

Thanks for reporting the issue.
I have fixed it, thanks to @jeremyletang.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants