Created
October 18, 2013 19:08
-
-
Save mynery/7046531 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main.rs:7:1: 7:11 error: type `ui::TBUI` does not implement any method in scope named `run` | |
| main,rs: | |
| pub mod ui; | |
| pub mod level; | |
| fn main() { | |
| let ui = ui::TBUI; | |
| let mut l = level::new(); | |
| ui.run(l); | |
| } | |
| ui.rs: | |
| use level; | |
| mod termbox; | |
| pub struct TBUI; | |
| pub trait UI { | |
| fn run(&self, l: level::Level); | |
| fn drawcell(&self, x: int, y: int, ch: char); | |
| fn present(&self); | |
| } | |
| impl UI for TBUI { | |
| fn run(&self, l: level::Level) { | |
| ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment