summary refs log tree commit diff
path: root/src/test/run-pass/module-polymorphism4-files/trait.rs
blob: 79296359d774f679421091cb8b667d3116752a58 (plain)
1
2
3
4
5
6
7
8
9
impl talky for T {

    // 'animal' and 'talk' functions are implemented by the module
    // instantiating the talky trait. They are 'abstract'
    fn says() -> str {
        animal() + " says '" + talk(self) + "'"
    }

}