aboutsummaryrefslogtreecommitdiff
path: root/gcc/line-map.c
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.demon.co.uk>2001-08-05 21:31:30 +0000
committerNeil Booth <neil@gcc.gnu.org>2001-08-05 21:31:30 +0000
commit6604e6f38d99e2e38f997d3ddb56a8fef06818b2 (patch)
treeba4516faab4daa3b5f2b20d3f9b83a34c0baede5 /gcc/line-map.c
parent67821e3a9e007c34a85bbc3b934031b57eafc903 (diff)
downloadgcc-6604e6f38d99e2e38f997d3ddb56a8fef06818b2.zip
gcc-6604e6f38d99e2e38f997d3ddb56a8fef06818b2.tar.gz
gcc-6604e6f38d99e2e38f997d3ddb56a8fef06818b2.tar.bz2
re PR preprocessor/3824 (With -traditional, CPP 0xffffffff > 0 but C 0xffffffff < 0)
PR preprocessor/3824 * line-map.c: Update comments. * line-map.h: Update comments. * tradcif.y: Don't consider large numbers unsigned. * gcc.dg/cpp/tr-sign.c: New testcase. From-SVN: r44651
Diffstat (limited to 'gcc/line-map.c')
-rw-r--r--gcc/line-map.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/line-map.c b/gcc/line-map.c
index a67191d..27bcf2f 100644
--- a/gcc/line-map.c
+++ b/gcc/line-map.c
@@ -93,7 +93,10 @@ add_line_map (set, reason, from_line, to_file, to_line)
return map;
}
-/* Translate a logical line number into a (source file, line) pair. */
+/* Given a logical line, returns the map from which the corresponding
+ (source file, line) pair can be deduced. Since the set is built
+ chronologically, the logical lines are monotonic increasing, and so
+ the list is sorted and we can use a binary search. */
struct line_map *
lookup_line (set, line)