1 /* expand-common - common functionality for expand/unexapnd
3 Copyright (C) 1989-2023 Free Software Foundation, Inc.
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <https://www.gnu.org/licenses/>. */
18 /* If true, convert blanks even after nonblank characters have been
20 extern bool convert_entire_line
;
22 /* The maximum distance between tab stops. */
23 extern size_t max_column_width
;
25 /* The desired exit status. */
26 extern int exit_status
;
28 /* Add tab stop TABVAL to the end of 'tab_list'. */
30 add_tab_stop (uintmax_t tabval
);
32 /* Add the comma or blank separated list of tab stops STOPS
33 to the list of tab stops. */
35 parse_tab_stops (char const *stops
) _GL_ATTRIBUTE_NONNULL ();
39 get_next_tab_column (const uintmax_t column
, size_t *tab_index
,
41 _GL_ATTRIBUTE_NONNULL ((3));
43 /* Called after all command-line options have been parsed,
44 sets the final tab-stops values */
46 finalize_tab_stops (void);
51 /* Sets new file-list */
53 set_file_list (char **file_list
);
55 /* Close the old stream pointer FP if it is non-null,
56 and return a new one opened to read the next input file.
57 Open a filename of '-' as the standard input.
58 Return nullptr if there are no more input files. */
64 cleanup_file_list_stdin (void);
68 emit_tab_list_info (void);