summaryrefslogtreecommitdiff
path: root/doc/UsersGuide
diff options
context:
space:
mode:
authortradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2004-04-23 23:26:37 +0000
committertradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2004-04-23 23:26:37 +0000
commit53f2cdce2d2ce92e9ecc21373155b4c639aa9c5e (patch)
tree36ab924a921c2805adaa924a7d7fe4663cd53fe7 /doc/UsersGuide
parentc7b2fb8af2d5f6a89f20e524ac564d2a380d689b (diff)
Document 'REQUIRES FUNCTION' to declare aliased functions which are required
to be provided. git-svn-id: http://svn.cactuscode.org/flesh/trunk@3672 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'doc/UsersGuide')
-rw-r--r--doc/UsersGuide/Appendices.tex8
-rw-r--r--doc/UsersGuide/ThornWriters.tex8
2 files changed, 14 insertions, 2 deletions
diff --git a/doc/UsersGuide/Appendices.tex b/doc/UsersGuide/Appendices.tex
index 255b90d0..59b40cee 100644
--- a/doc/UsersGuide/Appendices.tex
+++ b/doc/UsersGuide/Appendices.tex
@@ -397,7 +397,13 @@ CCTK_FPOINTER <\var{function_arg1}>(<\var{arg1_type}> <\var{intent1}> <\var{arg1
\end{alltt}
Function pointers may not be nested.
-If an aliased function is to be used then the block
+If an aliased function is to be required then the block
+\begin{alltt}
+REQUIRES FUNCTION <\var{alias}>
+\end{alltt}
+is required.
+
+If an aliased function is to be (optionally) used then the block
\begin{alltt}
USES FUNCTION <\var{alias}>
\end{alltt}
diff --git a/doc/UsersGuide/ThornWriters.tex b/doc/UsersGuide/ThornWriters.tex
index 076203a1..266fc023 100644
--- a/doc/UsersGuide/ThornWriters.tex
+++ b/doc/UsersGuide/ThornWriters.tex
@@ -3969,7 +3969,11 @@ interface.ccl} file. Declare the prototype as, for example,
\begin{verbatim}
CCTK_REAL FUNCTION SumStuff(CCTK_REAL IN x, CCTK_REAL IN y)
\end{verbatim}
-\noindent and that this function will be used in your thorn by
+\noindent and that this function will be either required in your thorn by
+\begin{verbatim}
+REQUIRES FUNCTION SumStuff
+\end{verbatim}
+\noindent or optionally used in your thorn by
\begin{verbatim}
USES FUNCTION SumStuff
\end{verbatim}
@@ -3984,6 +3988,8 @@ That is, the C prototype will expect an argument with intent {\tt IN}
to be a value and one with intent {\tt OUT} to be a pointer. There
also exists the {\tt ARRAY} keyword for passing arrays of any
dimension.
+Functions which are required by some thorn (which doesn't provide it itself)
+are checked at startup to be provided by some other thorn.
\subsection{Providing a function}