diff options
| author | Joakim Verona | 2011-09-05 10:37:16 +0200 |
|---|---|---|
| committer | Joakim Verona | 2011-09-05 10:37:16 +0200 |
| commit | 687faaf59cdf4029b5e8da16965b257592059e37 (patch) | |
| tree | c19fc758dc421ec1e6619de88d7cd70258927b47 /src/indent.c | |
| parent | d47f8c5baeaa804548a73675077c8e37cdfe5142 (diff) | |
| parent | f62bd846552a090f3ba5e136d6d9cdb4c07ed7be (diff) | |
| download | emacs-687faaf59cdf4029b5e8da16965b257592059e37.tar.gz emacs-687faaf59cdf4029b5e8da16965b257592059e37.zip | |
upstream
Diffstat (limited to 'src/indent.c')
| -rw-r--r-- | src/indent.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/indent.c b/src/indent.c index 313315e9081..6e602d28f60 100644 --- a/src/indent.c +++ b/src/indent.c | |||
| @@ -56,7 +56,7 @@ EMACS_INT last_known_column_point; | |||
| 56 | static int last_known_column_modified; | 56 | static int last_known_column_modified; |
| 57 | 57 | ||
| 58 | static EMACS_INT current_column_1 (void); | 58 | static EMACS_INT current_column_1 (void); |
| 59 | static EMACS_INT position_indentation (int); | 59 | static EMACS_INT position_indentation (ptrdiff_t); |
| 60 | 60 | ||
| 61 | /* Cache of beginning of line found by the last call of | 61 | /* Cache of beginning of line found by the last call of |
| 62 | current_column. */ | 62 | current_column. */ |
| @@ -855,7 +855,7 @@ following any initial whitespace. */) | |||
| 855 | } | 855 | } |
| 856 | 856 | ||
| 857 | static EMACS_INT | 857 | static EMACS_INT |
| 858 | position_indentation (register int pos_byte) | 858 | position_indentation (ptrdiff_t pos_byte) |
| 859 | { | 859 | { |
| 860 | register EMACS_INT column = 0; | 860 | register EMACS_INT column = 0; |
| 861 | int tab_width = SANE_TAB_WIDTH (current_buffer); | 861 | int tab_width = SANE_TAB_WIDTH (current_buffer); |
| @@ -2063,7 +2063,7 @@ whether or not it is currently displayed in some window. */) | |||
| 2063 | /* Do this even if LINES is 0, so that we move back to the | 2063 | /* Do this even if LINES is 0, so that we move back to the |
| 2064 | beginning of the current line as we ought. */ | 2064 | beginning of the current line as we ought. */ |
| 2065 | if (XINT (lines) == 0 || IT_CHARPOS (it) > 0) | 2065 | if (XINT (lines) == 0 || IT_CHARPOS (it) > 0) |
| 2066 | move_it_by_lines (&it, XINT (lines)); | 2066 | move_it_by_lines (&it, max (INT_MIN, XINT (lines))); |
| 2067 | } | 2067 | } |
| 2068 | else | 2068 | else |
| 2069 | { | 2069 | { |
| @@ -2083,7 +2083,7 @@ whether or not it is currently displayed in some window. */) | |||
| 2083 | && it.c == '\n')) | 2083 | && it.c == '\n')) |
| 2084 | move_it_by_lines (&it, -1); | 2084 | move_it_by_lines (&it, -1); |
| 2085 | it.vpos = 0; | 2085 | it.vpos = 0; |
| 2086 | move_it_by_lines (&it, XINT (lines)); | 2086 | move_it_by_lines (&it, min (INT_MAX, XINT (lines))); |
| 2087 | } | 2087 | } |
| 2088 | else | 2088 | else |
| 2089 | { | 2089 | { |
| @@ -2099,12 +2099,12 @@ whether or not it is currently displayed in some window. */) | |||
| 2099 | move_it_by_lines (&it, 1); | 2099 | move_it_by_lines (&it, 1); |
| 2100 | } | 2100 | } |
| 2101 | if (XINT (lines) > 1) | 2101 | if (XINT (lines) > 1) |
| 2102 | move_it_by_lines (&it, XINT (lines) - 1); | 2102 | move_it_by_lines (&it, min (INT_MAX, XINT (lines) - 1)); |
| 2103 | } | 2103 | } |
| 2104 | else | 2104 | else |
| 2105 | { | 2105 | { |
| 2106 | it.vpos = 0; | 2106 | it.vpos = 0; |
| 2107 | move_it_by_lines (&it, XINT (lines)); | 2107 | move_it_by_lines (&it, min (INT_MAX, XINT (lines))); |
| 2108 | } | 2108 | } |
| 2109 | } | 2109 | } |
| 2110 | } | 2110 | } |