Procedural Constants

To declare a procedural constant, specify the name of a function or procedure that is compatible with the declared type of the constant. For example, function Calc(X, Y: Integer): Integer; begin end;

type TFunction = function(X, Y: Integer): Integer; const MyFunction: TFunction = Calc;

Given these declarations, you can use the procedural constant MyFunction in a function call:

You can also assign the value nil to a procedural constant.

Project Management Made Easy

Project Management Made Easy

What you need to know about… Project Management Made Easy! Project management consists of more than just a large building project and can encompass small projects as well. No matter what the size of your project, you need to have some sort of project management. How you manage your project has everything to do with its outcome.

Get My Free Ebook


Post a comment