mirror of https://github.com/CGAL/cgal
Big renaming...
This commit is contained in:
parent
4b2bce06b4
commit
30949ff646
|
|
@ -5,13 +5,16 @@
|
|||
# Author: Sylvain Pion <Sylvain.Pion@sophia.inria.fr>.
|
||||
#
|
||||
#
|
||||
# This script takes as STDIN "predicates_on_ftC2.h" or equivalent.
|
||||
# It produces as STDOUT "Filter/predicates_on_ftC2.h" or equivalent.
|
||||
# This script takes as STDIN "predicates_on_ftC2.h" or equivalent.
|
||||
# It produces as STDOUT "Arithmetic_filter/predicates_on_ftC2.h" or equivalent.
|
||||
#
|
||||
# It is not supposed to be universal, and it can be considered a quick and
|
||||
# dirty hack. But it appears to work for CGAL's predicates.
|
||||
# It is not supposed to be universal, and it can be considered a quick and
|
||||
# dirty hack. But it appears to work for CGAL's predicates, so you might want
|
||||
# to use it for your predicates too (but the job can be done by hand if you
|
||||
# don't have many to do).
|
||||
#
|
||||
# See the CGAL documentation: Support Library, Number Types, CGAL_Filtering.
|
||||
# See the CGAL documentation:
|
||||
# Support Library, Number Types, CGAL_Filtered_exact.
|
||||
#
|
||||
|
||||
$in_header=1;
|
||||
|
|
@ -41,7 +44,7 @@ while (<>)
|
|||
result = $function_name(
|
||||
";
|
||||
foreach (@args) {
|
||||
print "\t\tCGAL_to_Interval_nt_advanced($_.value)";
|
||||
print "\t\tCGAL_convert_to<CGAL_Interval_nt_advanced>($_.value)";
|
||||
if ($_ ne $last_arg) { print ",\n"; }
|
||||
else { print ");"; }
|
||||
}
|
||||
|
|
@ -54,7 +57,7 @@ while (<>)
|
|||
result = $function_name(
|
||||
";
|
||||
foreach (@args) {
|
||||
print "\t\tCGAL_to_exact_type<ET>($_.value)";
|
||||
print "\t\tCGAL_convert_to<ET>($_.value)";
|
||||
if ($_ ne $last_arg) { print ",\n"; }
|
||||
else { print ");"; }
|
||||
}
|
||||
|
|
@ -91,7 +94,7 @@ while (<>)
|
|||
$last_arg=$1;
|
||||
}
|
||||
s/,[\s]*/,\n\t/g; # Split to make the lines < 80 characters.
|
||||
s/[RF]T/CGAL_Filtering<CT,ET>/g;
|
||||
s/[RF]T/CGAL_Filtered_exact<CT,ET>/g;
|
||||
}
|
||||
if (/\(/) {
|
||||
/([a-zA-Z_]\w*)\s*\(/;
|
||||
|
|
@ -106,7 +109,8 @@ while (<>)
|
|||
{
|
||||
s/\/\/ release[\s]*:.*/\/\/ release :/g;
|
||||
s/\/\/ release_date[\s]*:.*/\/\/ release_date :/g;
|
||||
if (/\/\/ file[\s]*: (.*)/) { $new_source_name= $1; s/CGAL/CGAL\/Filter/g; }
|
||||
if (/\/\/ file[\s]*: (.*)/)
|
||||
{ $new_source_name= $1; s/CGAL/CGAL\/Arithmetic_filter/g; }
|
||||
s/\/\/ package[\s]*:.*/\/\/ package : Interval_arithmetic/g;
|
||||
s/\/\/ source[\s]*:.*/\/\/ source : $new_source_name/g;
|
||||
s/\/\/ author\(s\)[\s]*:.*/\/\/ author(s) : Sylvain.Pion\@sophia.inria.fr/g;
|
||||
|
|
@ -122,11 +126,11 @@ while (<>)
|
|||
}
|
||||
|
||||
if (! $in_header)
|
||||
{ s/$old_protect_name/FILTER_$old_protect_name/g; }
|
||||
{ s/$old_protect_name/ARITHMETIC_FILTER_$old_protect_name/g; }
|
||||
|
||||
print $_;
|
||||
|
||||
if (/define[\s]*CGAL_FILTER_$old_protect_name/)
|
||||
if (/define[\s]*CGAL_ARITHMETIC_FILTER_$old_protect_name/)
|
||||
{
|
||||
print "
|
||||
// This file is automatically generated with the script for filtering
|
||||
|
|
|
|||
Loading…
Reference in New Issue