Variable length argument segfaults valac

Published 26 October, 2010 in Programming - 0 Comments

Hm, found a bug in valac (the Vala compiler) today. If an abstract or virtual method contains a variable length argument (va_list) valac will segmentation fault.

19 lines of Vala
  1. // valac -o test sample.vala
  2. int main(string[] args)
  3. {
  4. return 0;
  5. }
  6. public abstract class Base : Object
  7. {
  8. public abstract int query(string query, ... );
  9. }
  10. public class Child : Base
  11. {
  12. public override int query(string query, ... )
  13. {
  14. return 1;
  15. }
  16. }

I’ve filed a bug about it so we’ll see what the problem is and if it can be fixed rapidly.