! File: spec_expr_test.f90 ! Public domain 2005 James Van Buskirk ! Tests the compiler's mettle with the simplest of ! specification expressions. module funcs implicit none contains function f(x) character(*), intent(in) :: x integer f(len(x)) ! f = 42 ! Leads to deferencing the NULL pointer at runtime end function f end module funcs program spec_expr_test use funcs implicit none write(*,*) size(f('test')) end program spec_expr_test