Category "initialization"

non-trivial designated initializers not supported

I have a structure as follows: struct app_data { int port; int ib_port; unsigned size; int tx_depth; int sockfd; char *servername;

ruby: calling super without having a parent class

I have a class which overrides self.new and calls super in it, but the class doesn't derive from antoher class. So what exactly does the call? class Test att

How to initialize only few elements of an array with some values?

Is it possible to assign some values to an array instead of all? To clarify what I want: If I need an array like {1,0,0,0,2,0,0,0,3,0,0,0} I can create it like:

Initialize field before super constructor runs?

In Java, is there any way to initialize a field before the super constructor runs? Even the ugliest hacks I can come up with are rejected by the compiler: cla

Firebase Android - Skipping initialization

I am currently implementing an Android app, which uses Firebase Cloud Messaging. I've implemented everything according to the tutorial on the Firebase page. Ho

How do I initialize a two-dimensional List statically?

How can I initialize a multidimensional List statically? This works: List<List<Integer>> list = new ArrayList<List<Integer>>(); But