Say you are creating a java object like so:
SomeClass someObject = null;
someObject = new SomeClass();
At what point does the someObject become non-null? Is it before the SomeClass() constructor runs or after?
To clarify a little, say if another thread was to check if someObject was null while the SomeClass() constructor was halfway through completion, would it be null or non-null?
Also, what would be the difference if someObject was created like so:
SomeClass someObject = new SomeClass();
Would someObject ever be null?