Why is this an issue?

Lifetime specifiers are not allowed on method prototype declarations.

Even if some tools allow it, refrain from using this syntax to keep your code portable.

How to fix it

Code examples

Noncompliant code example

class Fly;
  extern function automatic void dream;
endclass

function automatic void Fly::dream;
endfunction

Compliant solution

class Fly;
  extern function void dream;
endclass

function automatic void Fly::dream;
endfunction