[Vala] Are nested interfaces disallowed?



Hi,

I have a class and I want to add a nested interface into it.

public class AClass : Object {
  public interface BClass : Object { public void foo() { } }
}

Valac 0.10.0 fails with following error:

a.vala:2.2-2.33: error: unexpected declaration in class
        public interface BClass : Object {
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

This sounds weird. If I change 'interface' to 'class' valac is ok with
it and compiles my program without any error.

What is the reason of nested interfaces prohibition?



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]