1! { dg-do compile } 2! This checks the fix for PR34813 in which the error at line 17 3! was not detected. 4! 5! Contributed by Daniel Franke <dfranke@gcc.gnu.org> 6! 7SUBROUTINE kd_tree_init_default() 8 TYPE :: kd_tree_node 9 INTEGER :: dummy 10 END TYPE 11 12 TYPE :: kd_tree 13 TYPE(kd_tree_node) :: root 14 END TYPE 15 16 TYPE(kd_tree) :: tree 17 tree = kd_tree(null()) ! { dg-error "neither a POINTER nor ALLOCATABLE" } 18END SUBROUTINE 19