A static function cannot be called on a non-initialized generic type (AJTERR10048)
| Product(s) | Karo.Net Compiler |
|---|
Description
A static function cannot be called directly from another function in this type in a generic type, as the type parameters are not initialized.
test::genericType<T> {
[static]
test ||: void { }
[static]
test2 ||: void {
test();
// ^^^^^^ Calling this function is not supported.
}
}
How can I resolve this error?
Initialize the type with type arguments. In the above example would genericType<string>:test() would be correct.