]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Support [CCode (scope = "async")] attribute for delegates
authorJürg Billeter <j@bitron.ch>
Thu, 2 Aug 2012 12:32:47 +0000 (14:32 +0200)
committerJürg Billeter <j@bitron.ch>
Thu, 2 Aug 2012 12:32:47 +0000 (14:32 +0200)
vala/valadelegatetype.vala

index 2cc6cf0db6ea5f693d71f67a449a8b8ede2b4458..91029d39e663881d76c2a9f17701394f7ed3a61e 100644 (file)
@@ -1,6 +1,6 @@
 /* valadelegatetype.vala
  *
- * Copyright (C) 2007-2010  Jürg Billeter
+ * Copyright (C) 2007-2012  Jürg Billeter
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -32,6 +32,7 @@ public class Vala.DelegateType : DataType {
 
        public DelegateType (Delegate delegate_symbol) {
                this.delegate_symbol = delegate_symbol;
+               this.is_called_once = (delegate_symbol.get_attribute_string ("CCode", "scope") == "async");
        }
 
        public override bool is_invokable () {