Consider the following code
module m
type SequenceBase
sequence
integer i
integer j
end type
end module
program typeDeclaration001d
use m
class(*), pointer :: mold1 => null()
type(SequenceBase) :: sb1
if(extends_type_of(sb1, mold1)) ERROR STOP(1_4) !! Should be diagnosed
if(same_type_as(sb1, mold1)) ERROR STOP(2_4) !! Should be diagnosed
end
A sequence derived type is not allowed in these two intrinsics.