You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm getting the following error when compiling using latest rustc.
C:\Rust\racer>rustc -O -o bin/racer src/main.rs
src\racer\codeiter.rs:22:10: 22:32 error: wrong number of type arguments: expected 0, found 1
src\racer\codeiter.rs:22 impl<'a> Iterator<(uint, uint)> for StmtIndicesIter<'a> {
The text was updated successfully, but these errors were encountered:
I just pulled this project and found the same problem when building. I managed to get it working, but I'm a total noob with rust, just starting to learn now.
In codeiter.rs, starting at line 22, change Iterator declaration and insert "type Item" declaration:
impl<'a> Iterator for StmtIndicesIter<'a> {
type Item = (uint, uint);
#[inline]
fn next(&mut self) -> Option<(uint, uint)> {
In codecleaner.rs, starting at line 38, same changes:
impl<'a> Iterator for CodeIndicesIter<'a> {
type Item = (uint, uint);
#[inline]
fn next(&mut self) -> Option<(uint, uint)> {
In main.rs, add new attribute:
#![feature(associated_types)]
That did it for me, hope this helps.
The latest racer commit I pulled is 389d84c. The versions of rustc and cargo that I have:
Hi,
I'm getting the following error when compiling using latest rustc.
The text was updated successfully, but these errors were encountered: