about summary refs log tree commit diff
path: root/src/rt/rust_obstack.cpp
diff options
context:
space:
mode:
authorMarijn Haverbeke <marijnh@gmail.com>2011-12-20 16:33:55 +0100
committerMarijn Haverbeke <marijnh@gmail.com>2011-12-23 18:09:25 +0100
commit057617c6654bfd5a677112cd26141d0b9c137145 (patch)
tree316c1b2cbcb11aa3cd02f05107e76fa5cd624fef /src/rt/rust_obstack.cpp
parent92927449595782926c4db5a579ba7e4c6952287d (diff)
downloadrust-057617c6654bfd5a677112cd26141d0b9c137145.tar.gz
rust-057617c6654bfd5a677112cd26141d0b9c137145.zip
Parse `iface` items and interface references in `impl` items.
The (temporary) syntax is

    iface seq<T> {
        fn len() -> uint;
        fn iter(f: block(T));
    }

    // The 'blah<T>' can be left of to default the name of the
    // impl to seq<T>. The 'of seq<T>' can be left off when
    // not implementing a named interface.
    impl blah<T> of seq<T> for [T] {
        fn len() -> uint { vec::len(self) }
        fn iter(f: block(T)) { for x in self { f(x); } }
    }
Diffstat (limited to 'src/rt/rust_obstack.cpp')
0 files changed, 0 insertions, 0 deletions