From c3ec02e0ce631f95b3134f5111dbe4c7a9172af3 Mon Sep 17 00:00:00 2001 From: michael Date: Wed, 9 Sep 1998 18:22:36 +0000 Subject: [PATCH] error in compiler info directive --- docs/prog.tex | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/docs/prog.tex b/docs/prog.tex index 7d40664bc4..3ea3f158dc 100644 --- a/docs/prog.tex +++ b/docs/prog.tex @@ -401,8 +401,30 @@ In this form: where \var{xxx} is one of \var{TIME}, \var{DATE}, \var{FPCVERSION} or \var{FPCTARGET}, will generate a macro with the value of these things. If \var{xxx} is none of the above, then it is assumed to be the value of -an environment variable. It's value will be fetched. +an environment variable. It's value will be fetched, and inserted in the coe +as if it were a srtring. +For example, the following program +\begin{verbatim} +Program InfoDemo; + +Const User = {$I %USER%}; + +begin + Write ('This program was comilped at ',{$I %TIME%}); + Writeln (' on ',{$I %DATE%}); + Writeln ('By ',User); + Writeln ('Compiler version : ',{$I %FPCVERSION%}); + Writeln ('Target CPU : ',{$I %FPCTARGET%}); +end. +\end{verbatim} +Creates the following output : +\begin{verbatim} +This program was comilped at 17:40:18 on 1998/09/09 +By michael +Compiler version : 0.99.7 +Target CPU : i386 +\end{verbatim} % Assembler type \subsection{\var{\$I386\_XXX} : Specify assembler format}