Try
declare
c varchar2(4000);
begin;
select testfunc into c from dual;
end;
/
Also I think you should use
PRAGMA RESTRICT_REFERENCES (testfunc, WNDS);
in your function (not sure, but I think in 8.0.5 you should).