-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
thread 'rustc' panicked at 'index out of bounds: [...] src/libcollections/vec.rs:1047 #28217
Comments
Looking at the backtrace this looks like it's a bug in the json plugin, not the compiler? |
Looking at #[stable(feature = "rust1", since = "1.0.0")]
impl<T> Index<usize> for Vec<T> {
type Output = T;
#[inline]
fn index(&self, index: usize) -> &T {
// NB built-in indexing via `&[T]`
&(**self)[index]
}
} |
While this is a bug in the library, it shouldnt be possible for a library to cause an ICE |
@steveklabnik Panics from plugins (either if the plugin panics or calls an internal function incorrectly, causing a panic), are reported as ICEs by the compiler. So it is possible for a library to cause an ICE, though in this case I suspect that this is a "true" ICE. @alexcrichton I don't think there are any cases where I do recall seeing an error in InternedString recently (in the same function), but I completely forgot how it was caused. |
This no longer works on current nightlies because the syntax extensions have changed since the bug was filed. As such, I'm going to give it a close. |
I can't use the
json!
macro on latestmaster
(2015-09-03).I tried this code:
src/main.rs
Cargo.toml:
I expected to see this happen:
{"test":"1"}
Instead, this happened:
note: the compiler unexpectedly panicked. this is a bug.
Meta
rustc --version --verbose
:cargo --version
:Backtrace:
(I broke the output into three so it's more obvious where the backtrace begins and ends.)
Let me know if there's anything else I can add or try.
The text was updated successfully, but these errors were encountered: