mirror of https://github.com/CGAL/cgal
This commit introduces a new kind of predicate in
`<CGAL/Kernel/interface_macros.h>`. In addition to
- `CGAL_kernel_pred` for predicates,
- `CGAL_Kernel_pred_RT` for predicates that can be implemented using a
ring-type,
now there is also:
- `CGAL_Kernel_pred_RT_or_FT` for predicates with multiple overloads of
`operator()`, some needing a field type and other needing a ring type
(without the division operator).
The C++ code can discriminate between the two cases with a special wrapper
for the return type: `CGAL::Needs_FT<result_type` instead of `result_type`
(defined in `<CGAL/tags.h>`.
In `<CGAL/Filtered_predicate.h>`, in addition to the usual class template
`Filtered_predicate`, there is now also `Filtered_predicate_RT_FT` that
takes three predicates as template parameters instead of two:
- the exact predicate with an ring-type,
- the exact predicate with a field-type,
- the approximate predicate (with `Interval_nt` as number-type).
For the moment, only `Compare_distance_3` in
`<CGAL/Cartesian/function_objects.h>` is using the new
`Filtered_predicate_RT_FT`.
Before this commit, the file
`Kernel_23/test/Kernel_23/include/CGAL/_test_new_3.h` was testing
`Compare_distance_3` only with three points or for points. This commit adds:
- a test with `Point_3, Point_3, Segment_3`, and
- a test with `Line_3, Point_3, Point_3`, that actually needs a field type
with its current implementation.
In the test `Kernel_23/test/Kernel_23/Filtered_cartesian.cpp`, the macro
`CGAL_NO_MPZF_DIVISION_OPERATOR` is defined, to remove the division operator
from `CGAL::Mpzf`. `CGAL::Mpzf` is a ring-type, even with its `operator/`
(because that `operator/` can only compute exact divisions), but with
`CGAL_NO_MPZF_DIVISION_OPERATOR` defined, that is now checked by the compiler.
|
||
|---|---|---|
| .. | ||
| auxiliary | ||
| cmake/modules | ||
| demo | ||
| doc_html | ||
| examples | ||
| include/CGAL | ||
| lib/cmake/CGAL | ||
| package_info/Installation | ||
| test | ||
| AUTHORS | ||
| CGALConfig.cmake | ||
| CGALConfigVersion.cmake | ||
| CHANGES.md | ||
| CMakeLists.txt | ||
| INSTALL.md | ||
| LICENSE | ||
| LICENSE.BSL | ||
| LICENSE.COMMERCIAL | ||
| LICENSE.GPL | ||
| LICENSE.LGPL | ||
| LICENSE.RFL | ||
| README | ||
README
README
-------------------------------------------------------------------------------
This distribution of CGAL includes:
AUTHORS - current and former authors of CGAL
CHANGES - history of changes for the library
CMakeLists.txt - main script of the build system
INSTALL.md - information about the installation process
LICENSE - describes the license of CGAL
LICENSE.FREE_USE - text of the free use license (see LICENSE file)
LICENSE.GPL - text of GPL v3 license
LICENSE.LGPL - text of LGPL v3 license
README - this file
VERSION - version number of this release
auxiliary/ - directory containing miscellaneous things, currently only
the icons needed for the demos on MacOS X
cmake/ - some scripts needed by the build system
config/ - some test programs used during the configuration process
demo/ - many demo programs for the library's various packages.
These programs produce visual output (see INSTALL for
prerequisites).
doc_html/ - documentation, e.g. the CGAL Installation Guide
examples/ - programs illustrating the library's functionality.
These programs do not produce visual output.
include/ - the include files for the CGAL library (and other small
external libraries as well, see the LICENSE file)
scripts/ - some useful scripts for CGAL programmers
src/ - the source code for building the CGAL libraries
(as well as some external libraries, see the LICENSE file)
-------------------------------------------------------------------------------