mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 22:14:25 +02:00
Avoid warning for function not set if noreturn modifier is used
git-svn-id: trunk@29710 -
This commit is contained in:
parent
fdb09365ba
commit
af883cdcb7
@ -712,6 +712,7 @@ implementation
|
|||||||
{ don't warn about the result of constructors }
|
{ don't warn about the result of constructors }
|
||||||
if ((tsym(sym).owner.symtabletype<>localsymtable) or
|
if ((tsym(sym).owner.symtabletype<>localsymtable) or
|
||||||
(tprocdef(tsym(sym).owner.defowner).proctypeoption<>potype_constructor)) and
|
(tprocdef(tsym(sym).owner.defowner).proctypeoption<>potype_constructor)) and
|
||||||
|
not (po_noreturn in tprocdef(tsym(sym).owner.defowner).procoptions) and
|
||||||
not(cs_opt_nodedfa in current_settings.optimizerswitches) then
|
not(cs_opt_nodedfa in current_settings.optimizerswitches) then
|
||||||
MessagePos(tsym(sym).fileinfo,sym_w_function_result_not_set)
|
MessagePos(tsym(sym).fileinfo,sym_w_function_result_not_set)
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user