The result is completely identical. The assignment sign =>
can be also used for variable initialization or derived type components default initialization, where the nullify
statement is unusable, but that is only a syntactic thing, it is not a proper assignment in fact.
For example
type t
real, pointer :: ptr => null()
end type
is the default initialization of a component, and
program p
real, pointer :: ptr2 => null()
is initialization of a variable. The variable ptr2
is implicitly save
as any other initialized variable (a common source of errors).