(j3.2006) same types

Michael Ingrassia michaeli
Thu Nov 1 19:36:39 EDT 2007


If you think having different default initializations is counterintuitive, 
how about the fact that two types that are 
"the same type" can even have different names!
The inliner had better not collapse too many type table entries together.

Exercise left to the reader.
	--Michael I.



ANSWERS TO EXERCISES

module foo
type x
    sequence
    integer :: i = 3
endtype
end module foo

module bar
use foo
end module bar

use foo, different_name => x
use bar
type (x) :: A
type (different_name) :: B

print *, A%i, B%i              ! A and B have the same type
end



More information about the J3 mailing list