[Vala] Defining a new type



Hello,

I'm trying to define a new type from a HashTable. The Vala tutorial has an example on this, but it seems disfunctional/incomplete and is not explained. Based on the example, I tried this:

class LexerDefinition: HashTable<string, LexerNode>  {

        [CCode (has_construct_function = false)]        // ??
        public LexerDefinition() {
                base(str_hash, str_equal);
        }
}


Vala doesn't complain about errors in the above code but c-code compilation fails with "too few arguments for function g_hash_table_new_full". What am I doing wrong?

Thanks,
  Dennis



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