diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2021-03-17 15:52:22 +0100 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2021-03-17 16:34:11 +0100 |
| commit | f4bd832184b5ebcc5b18b0d625628cf7dd7e969a (patch) | |
| tree | 7c3abf961ad29d257e80c323feff36a4f9d8ccf0 | |
| parent | 861ae257f4f640dacc71528079ab6d56c8d39e80 (diff) | |
| download | PROJ-f4bd832184b5ebcc5b18b0d625628cf7dd7e969a.tar.gz PROJ-f4bd832184b5ebcc5b18b0d625628cf7dd7e969a.zip | |
Doc: add a page to document macros
| -rw-r--r-- | docs/source/development/reference/index.rst | 1 | ||||
| -rw-r--r-- | docs/source/development/reference/macros.rst | 39 |
2 files changed, 40 insertions, 0 deletions
diff --git a/docs/source/development/reference/index.rst b/docs/source/development/reference/index.rst index caa893c3..f04f4b3e 100644 --- a/docs/source/development/reference/index.rst +++ b/docs/source/development/reference/index.rst @@ -7,6 +7,7 @@ Reference .. toctree:: :maxdepth: 1 + macros datatypes functions cpp/index.rst diff --git a/docs/source/development/reference/macros.rst b/docs/source/development/reference/macros.rst new file mode 100644 index 00000000..131b8e72 --- /dev/null +++ b/docs/source/development/reference/macros.rst @@ -0,0 +1,39 @@ +.. _macros: + +================================================================================ +Macros +================================================================================ + +.. c:macro:: PROJ_VERSION_MAJOR + + Major version number, e.g 8 for PROJ 8.0.1 + +.. c:macro:: PROJ_VERSION_MINOR + + Minor version number, e.g 0 for PROJ 8.0.1 + +.. c:macro:: PROJ_VERSION_PATCH + + Patch version number, e.g 1 for PROJ 8.0.1 + +.. c:macro:: PROJ_COMPUTE_VERSION(maj,min,patch) + + .. versionadded:: 8.0.1 + + Compute the version number from the major, minor and patch numbers. + +.. c:macro:: PROJ_VERSION_NUMBER + + .. versionadded:: 8.0.1 + + Total version number, equal to + ``PROJ_COMPUTE_VERSION(PROJ_VERSION_MAJOR, PROJ_VERSION_MINOR, PROJ_VERSION_PATCH)`` + +.. c:macro:: PROJ_AT_LEAST_VERSION(maj,min,patch) + + .. versionadded:: 8.0.1 + + Macro that returns true if the current PROJ version is at least the version + specified by (maj,min,patch) + + Equivalent to ``PROJ_VERSION_NUMBER >= PROJ_COMPUTE_VERSION(maj,min,patch)`` |
