I agree with Thaddy's "mixed feelings" - the macros samples here looks like rather a mess but I understand why the author used them. His matrix is a simple record
type TMatrix=record
columns, rows : longint; { columns, rows }
ref,sr : longint; { reference counts }
data : ^float;
end;
and he needed a simple way to access the elements M[i,j], avoiding cumbersome constructs such as M.data[M.columns*i+j]. If we cannot use getters/setters because they are too slow, neither want to do pointer arithmetics, parameterised macros may not be the worst of all solutions.