~ubuntu-branches/ubuntu/raring/vala-0.20/raring-proposed

« back to all changes in this revision

Viewing changes to tests/methods/bug639054.vala

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher
  • Date: 2013-04-05 13:45:05 UTC
  • Revision ID: package-import@ubuntu.com-20130405134505-yyk3rec9904i7p8o
Tags: upstream-0.20.1
ImportĀ upstreamĀ versionĀ 0.20.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
[Compact]
 
2
public class Baz {
 
3
}
 
4
 
 
5
public async void foo (uint8[] bar, Baz baz) {
 
6
        SourceFunc f = () => {
 
7
                bar[0] = 'b';
 
8
                baz = null;
 
9
                return false;
 
10
        };
 
11
        f ();
 
12
}
 
13
 
 
14
void main () {
 
15
        var loop = new MainLoop ();
 
16
        var bar = "foo".data;
 
17
        foo.begin (bar, new Baz (), () => {
 
18
                assert (bar[0] == 'b');
 
19
                loop.quit ();
 
20
        });
 
21
        loop.run ();
 
22
}