From: Dhruv Chawla <[email protected]>
Signed-off-by: Dhruv Chawla <[email protected]>
libcpp/ChangeLog:
* files.cc (_cpp_stack_translated_file): Fix typos.
(_cpp_get_file_path): Likewise.
* include/cpplib.h (PREV_FALLTHROUGH): Likewise.
(struct cpp_options): Likewise.
* include/line-map.h (enum lc_reason): Likewise.
* internal.h (struct cpp_buffer): Likewise.
* lex.cc (lex_raw_string): Likewise.
(cpp_directive_only_process): Likewise.
* line-map.cc (linemap_add): Likewise.
(linemap_module_restore): Likewise.
(rich_location::get_last_fixit_hint): Likewise.
* macro.cc (_cpp_builtin_macro_text): Likewise.
(arg_token_ptr_at): Likewise.
(replace_args): Likewise.
(reached_end_of_context): Likewise.
(cpp_get_token_1): Likewise.
(create_iso_definition): Likewise.
(get_deferred_or_lazy_macro): Likewise.
* traditional.cc (check_output_buffer): Likewise.
---
libcpp/files.cc | 4 ++--
libcpp/include/cpplib.h | 4 ++--
libcpp/include/line-map.h | 2 +-
libcpp/internal.h | 2 +-
libcpp/lex.cc | 4 ++--
libcpp/line-map.cc | 6 +++---
libcpp/macro.cc | 16 ++++++++--------
libcpp/traditional.cc | 2 +-
8 files changed, 20 insertions(+), 20 deletions(-)
diff --git a/libcpp/files.cc b/libcpp/files.cc
index 9234ead0d23..917b7799be9 100644
--- a/libcpp/files.cc
+++ b/libcpp/files.cc
@@ -1007,7 +1007,7 @@ _cpp_stack_translated_file (cpp_reader *pfile, _cpp_file
*file,
/* We don't increment the line number at the end of a buffer,
because we don't usually need that location (we're popping an
include file). However in this case we do want to do the
- increment. So push a writable buffer of two newlines to acheive
+ increment. So push a writable buffer of two newlines to achieve
that. (We also need an extra newline, so this looks like a regular
file, which we do that to to make sure we don't fall off the end in the
middle of a line. */
@@ -2377,7 +2377,7 @@ _cpp_get_file_path (_cpp_file *f)
return f->path;
}
-/* Inteface to file statistics record in _cpp_file structure. */
+/* Interface to file statistics record in _cpp_file structure. */
struct stat *
_cpp_get_file_stat (_cpp_file *file)
{
diff --git a/libcpp/include/cpplib.h b/libcpp/include/cpplib.h
index bc0d7714e96..e8c35cd68d7 100644
--- a/libcpp/include/cpplib.h
+++ b/libcpp/include/cpplib.h
@@ -201,7 +201,7 @@ struct GTY(()) cpp_string {
#define STRINGIFY_ARG (1 << 2) /* If macro argument to be stringified. */
#define PASTE_LEFT (1 << 3) /* If on LHS of a ## operator. */
#define NAMED_OP (1 << 4) /* C++ named operators. */
-#define PREV_FALLTHROUGH (1 << 5) /* On a token preceeded by FALLTHROUGH
+#define PREV_FALLTHROUGH (1 << 5) /* On a token preceded by FALLTHROUGH
comment. */
#define DECIMAL_INT (1 << 6) /* Decimal integer, set in c-lex.cc. */
#define PURE_ZERO (1 << 7) /* Single 0 digit, used by the C++ frontend,
@@ -515,7 +515,7 @@ struct cpp_options
unsigned char user_literals;
/* Nonzero means warn when a string or character literal is followed by a
- ud-suffix which does not beging with an underscore. */
+ ud-suffix which does not begin with an underscore. */
unsigned char warn_literal_suffix;
/* Nonzero means interpret imaginary, fixed-point, or other gnu extension
diff --git a/libcpp/include/line-map.h b/libcpp/include/line-map.h
index 23060299e94..dae777a02d6 100644
--- a/libcpp/include/line-map.h
+++ b/libcpp/include/line-map.h
@@ -142,7 +142,7 @@ enum lc_reason
| This packing scheme means we effectively have
| (column_bits - range_bits)
| of bits for the columns, typically (12 - 5) = 7, for 128
- | columns; longer line widths are accomodated by starting a
+ | columns; longer line widths are accommodated by starting a
| new ordmap with a higher column_bits.
|
| ordmap[2]->start_location-1 | Final location in ordmap 1
diff --git a/libcpp/internal.h b/libcpp/internal.h
index 017e980a964..f7b7ac3ddb2 100644
--- a/libcpp/internal.h
+++ b/libcpp/internal.h
@@ -359,7 +359,7 @@ struct cpp_buffer
struct _cpp_file *file;
/* Saved value of __TIMESTAMP__ macro - date and time of last modification
- of the assotiated file. */
+ of the associated file. */
const unsigned char *timestamp;
/* Value of if_stack at start of this file.
diff --git a/libcpp/lex.cc b/libcpp/lex.cc
index 9652e7d5aae..391c487bbc1 100644
--- a/libcpp/lex.cc
+++ b/libcpp/lex.cc
@@ -2631,7 +2631,7 @@ lex_raw_string (cpp_reader *pfile, cpp_token *token,
const uchar *base)
case '\n':
/* This can happen for ??/<NEWLINE> when trigraphs are not
- being interpretted. */
+ being interpreted. */
gcc_checking_assert (!CPP_OPTION (pfile, trigraphs));
note->type = 0;
note++;
@@ -5416,7 +5416,7 @@ cpp_directive_only_process (cpp_reader *pfile,
case '\\':
/* <backslash><newline> is removed, and doesn't undo any
- preceeding escape or whatnot. */
+ preceding escape or whatnot. */
if (*pos == '\n')
{
pos++;
diff --git a/libcpp/line-map.cc b/libcpp/line-map.cc
index 34f3642258d..0d44750f664 100644
--- a/libcpp/line-map.cc
+++ b/libcpp/line-map.cc
@@ -679,7 +679,7 @@ linemap_add (line_maps *set, enum lc_reason reason,
else
{
/* Compute location from whence this line map was included.
- For #include this should be preferrably column 0 of the
+ For #include this should be preferably column 0 of the
line on which #include directive appears.
map[-1] is the just closed map and usually included_from
falls within that map. In rare cases linemap_line_start
@@ -757,7 +757,7 @@ linemap_module_restore (line_maps *set, line_map_uint_t lwm)
ORDINARY_MAP_IN_SYSTEM_HEADER_P (pre_map),
ORDINARY_MAP_FILE_NAME (pre_map), src_line))))
{
- /* linemap_add will think we were included from the same as the
preceeding
+ /* linemap_add will think we were included from the same as the preceding
map. */
const_cast <line_map_ordinary *> (post_map)->included_from = inc_at;
@@ -2556,7 +2556,7 @@ rich_location::get_last_fixit_hint () const
}
/* If WHERE is an "awkward" location, then mark this rich_location as not
- supporting fixits, purging any thay were already added, and return true.
+ supporting fixits, purging any that were already added, and return true.
Otherwise (the common case), return false. */
diff --git a/libcpp/macro.cc b/libcpp/macro.cc
index c29a34302b6..347bcaa70d0 100644
--- a/libcpp/macro.cc
+++ b/libcpp/macro.cc
@@ -582,7 +582,7 @@ _cpp_builtin_macro_text (cpp_reader *pfile, cpp_hashnode
*node,
cpp_buffer *pbuffer = cpp_get_buffer (pfile);
if (pbuffer->timestamp == NULL)
{
- /* Initialize timestamp value of the assotiated file. */
+ /* Initialize timestamp value of the associated file. */
struct _cpp_file *file = cpp_get_file (pbuffer);
if (file)
{
@@ -1800,7 +1800,7 @@ arg_token_ptr_at (const macro_arg *arg, size_t index,
if (tokens_ptr == NULL)
/* This can happen for e.g, an empty token argument to a
- funtion-like macro. */
+ function-like macro. */
return tokens_ptr;
if (virt_location)
@@ -2247,7 +2247,7 @@ replace_args (cpp_reader *pfile, cpp_hashnode *node,
cpp_macro *macro,
/* SRC is a macro parameter that we need to replace with its
corresponding argument. So at some point we'll need to
iterate over the tokens of the macro argument and copy them
- into the "place" now holding the correspondig macro
+ into the "place" now holding the corresponding macro
parameter. We are going to use the iterator type
macro_argo_token_iter to handle that iterating. The 'if'
below is to initialize the iterator depending on the type of
@@ -2931,7 +2931,7 @@ reached_end_of_context (cpp_context *context)
/* Consume the next token contained in the current context of PFILE,
and return it in *TOKEN. It's "full location" is returned in
- *LOCATION. If -ftrack-macro-location is in effeect, fFull location"
+ *LOCATION. If -ftrack-macro-location is in effect, fFull location"
means the location encoding the locus of the token across macro
expansion; otherwise it's just is the "normal" location of the
token which (*TOKEN)->src_loc. */
@@ -3009,7 +3009,7 @@ cpp_get_token_1 (cpp_reader *pfile, location_t *location)
/* This token is a virtual token that either encodes a location
related to macro expansion or a spelling location. */
location_t virt_loc = 0;
- /* pfile->about_to_expand_macro_p can be overriden by indirect calls
+ /* pfile->about_to_expand_macro_p can be overridden by indirect calls
to functions that push macro contexts. So let's save it so that
we can restore it when we are about to leave this routine. */
bool saved_about_to_expand_macro = pfile->about_to_expand_macro_p;
@@ -3160,7 +3160,7 @@ cpp_get_token_1 (cpp_reader *pfile, location_t *location)
&& !(result->type == CPP_PADDING || result->type == CPP_COMMENT)
&& !(15 & --pfile->state.directive_file_token))
{
- /* Do header-name frobbery. Concatenate < ... > as approprate.
+ /* Do header-name frobbery. Concatenate < ... > as appropriate.
Do header search if needed, and finally drop the outer <> or
"". */
pfile->state.angled_headers = false;
@@ -3710,7 +3710,7 @@ create_iso_definition (cpp_reader *pfile)
pfile->cur_token = saved_cur_token;
if (token->flags & PREV_WHITE)
- /* Preceeded by space, must be part of expansion. */;
+ /* Preceded by space, must be part of expansion. */;
else if (token->type == CPP_OPEN_PAREN)
{
/* An open-paren, get a parameter list. */
@@ -4074,7 +4074,7 @@ get_deferred_or_lazy_macro (cpp_reader *pfile,
cpp_hashnode *node,
}
/* Notify the use of NODE in a macro-aware context (i.e. expanding it,
- or testing its existance). Also applies any lazy definition.
+ or testing its existence). Also applies any lazy definition.
Return FALSE if the macro isn't really there. */
extern bool
diff --git a/libcpp/traditional.cc b/libcpp/traditional.cc
index b0913187b8b..2ed07bc7346 100644
--- a/libcpp/traditional.cc
+++ b/libcpp/traditional.cc
@@ -120,7 +120,7 @@ check_output_buffer (cpp_reader *pfile, size_t n)
/* Skip a C-style block comment in a macro as a result of -CC.
PFILE->buffer->cur points to the initial asterisk of the comment,
change it to point to after the '*' and '/' characters that terminate it.
- Return true if the macro has not been termined, in that case set
+ Return true if the macro has not been terminated, in that case set
PFILE->buffer->cur to the end of the buffer. */
static bool
skip_macro_block_comment (cpp_reader *pfile)
--
2.43.0