Delphi Error – E2537 DEFAULT standard function expects a type identifier

Delphi Compiler Error

E2537 DEFAULT standard function expects a type identifier

Reason for the Error & Solution

This occurs when using a method instead of a type with the Default function.

program E2537;

{$APPTYPE CONSOLE}

uses
  SysUtils;

var
    p : Pointer;

procedure NotType;
  begin
  end;

begin
  p := Default(NotType);
end.

Share:

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

Delphi Compiler Error E2313 Attribute – Known attribute cannot specify properties Reason for the Error & Solution No further information...
Delphi Compiler Error E2379 Virtual methods not allowed in record types Reason for the Error & Solution No further information...
Rodrigo , one of the long time Delphi Developer has been working on one of his personal project “Delphi IDE...