summaryrefslogtreecommitdiff
path: root/usr.bin/xlint/lint1
diff options
context:
space:
mode:
authorChad Loder <cloder@cvs.openbsd.org>2005-11-28 04:57:05 +0000
committerChad Loder <cloder@cvs.openbsd.org>2005-11-28 04:57:05 +0000
commit06c351053d058e75607c010e182499744e1f11db (patch)
tree736c27bb85ce9f41457f5f1ae95f63f20578cee7 /usr.bin/xlint/lint1
parent6d9a724617112d4a141e7ea970081d033a282cad (diff)
Typos in comments
Diffstat (limited to 'usr.bin/xlint/lint1')
-rw-r--r--usr.bin/xlint/lint1/tree.c52
1 files changed, 26 insertions, 26 deletions
diff --git a/usr.bin/xlint/lint1/tree.c b/usr.bin/xlint/lint1/tree.c
index 0f615d79a26..19fefbd8639 100644
--- a/usr.bin/xlint/lint1/tree.c
+++ b/usr.bin/xlint/lint1/tree.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tree.c,v 1.13 2005/11/28 03:12:52 cloder Exp $ */
+/* $OpenBSD: tree.c,v 1.14 2005/11/28 04:57:04 cloder Exp $ */
/* $NetBSD: tree.c,v 1.12 1995/10/02 17:37:57 jpo Exp $ */
/*
@@ -33,7 +33,7 @@
*/
#ifndef lint
-static char rcsid[] = "$OpenBSD: tree.c,v 1.13 2005/11/28 03:12:52 cloder Exp $";
+static char rcsid[] = "$OpenBSD: tree.c,v 1.14 2005/11/28 04:57:04 cloder Exp $";
#endif
#include <stdlib.h>
@@ -538,7 +538,7 @@ build(op_t op, tnode_t *ln, tnode_t *rn)
/*
* Apply class conversions to the left operand, but only if its
- * value is needed or it is compaired with null.
+ * value is needed or it is compared with null.
*/
if (mp->m_vctx || mp->m_tctx)
ln = cconv(ln);
@@ -595,7 +595,7 @@ build(op_t op, tnode_t *ln, tnode_t *rn)
/*
* Check types for compatibility with the operation and mutual
- * compatibility. Return if there are serios problems.
+ * compatibility. Return if there are serious problems.
*/
if (!typeok(op, 0, ln, rn))
return (NULL);
@@ -712,7 +712,7 @@ cconv(tnode_t *tn)
*/
if (tn->tn_type->t_tspec == ARRAY) {
if (!tn->tn_lvalue) {
- /* %soperand of '%s' must be lvalue */
+ /* operand of '%s' must be lvalue */
/* XXX print correct operator */
(void)gnuism(114, "", modtab[AMPER].m_name);
}
@@ -740,7 +740,7 @@ cconv(tnode_t *tn)
/*
* Perform most type checks. First the types are checked using
- * informations from modtab[]. After that it is done by hand for
+ * information from modtab[]. After that it is done by hand for
* more complicated operators and type combinations.
*
* If the types are ok, typeok() returns 1, otherwise 0.
@@ -764,7 +764,7 @@ typeok(op_t op, int arg, tnode_t *ln, tnode_t *rn)
}
if (mp->m_rqint) {
- /* integertypes required */
+ /* integer types required */
if (!isityp(lt) || (mp->m_binary && !isityp(rt))) {
incompat(op, lt, rt);
return (0);
@@ -798,11 +798,11 @@ typeok(op_t op, int arg, tnode_t *ln, tnode_t *rn)
case POINT:
/*
* Most errors required by ANSI C are reported in strmemb().
- * Here we only must check for totaly wrong things.
+ * Here we only must check for totally wrong things.
*/
if (lt == FUNC || lt == VOID || ltp->t_isfield ||
((lt != STRUCT && lt != UNION) && !ln->tn_lvalue)) {
- /* Without tflag we got already an error */
+ /* Without tflag we already have an error */
if (tflag)
/* unacceptable operand of %s */
error(111, mp->m_name);
@@ -812,9 +812,9 @@ typeok(op_t op, int arg, tnode_t *ln, tnode_t *rn)
break;
case ARROW:
if (lt != PTR && !(tflag && isityp(lt))) {
- /* Without tflag we got already an error */
+ /* Without tflag we already have an error */
if (tflag)
- /* unacceptabel operand of %s */
+ /* unacceptable operand of %s */
error(111, mp->m_name);
return (0);
}
@@ -936,7 +936,7 @@ typeok(op_t op, int arg, tnode_t *ln, tnode_t *rn)
}
}
- /* questionable right shift of %d-bit quantity by %d bits */
+ /* right shift of %d-bit quantity by %d bits */
if (rn->tn_op == CON && size(olt) <= rn->tn_val->v_quad)
warning(310, size(olt), rn->tn_val->v_quad);
@@ -1090,11 +1090,11 @@ typeok(op_t op, int arg, tnode_t *ln, tnode_t *rn)
goto assign;
case SHRASS:
if (pflag && !isutyp(lt) && !(tflag && isutyp(rt))) {
- /* bitwise operation on s.v. possibly nonportabel */
+ /* bitwise operation on s.v. possibly nonportable */
warning(117);
}
- /* questionable right shift of %d-bit quantity by %d bits */
+ /* right shift of %d-bit quantity by %d bits */
if (rn->tn_op == CON && size(olt) <= rn->tn_val->v_quad)
warning(310, size(olt), rn->tn_val->v_quad);
@@ -1711,7 +1711,7 @@ ptconv(int arg, tspec_t nt, tspec_t ot, type_t *tp, tnode_t *tn)
}
/*
- * Print warnings for conversions of integer types which my cause
+ * Print warnings for conversions of integer types which may cause
* problems.
*/
/* ARGSUSED */
@@ -1761,7 +1761,7 @@ piconv(op_t op, tspec_t nt, type_t *tp, tnode_t *tn)
return;
if (op != CVT) {
- /* We got already an error. */
+ /* We already have an error. */
return;
}
@@ -1786,7 +1786,7 @@ ppconv(op_t op, tnode_t *tn, type_t *tp)
const char *nts, *ots;
/*
- * We got already an error (pointers of different types
+ * We already have an error (pointers of different types
* without a cast) or we will not get a warning.
*/
if (op != CVT)
@@ -1828,11 +1828,11 @@ ppconv(op_t op, tnode_t *tn, type_t *tp)
}
/*
- * Converts a typed constant in a constant of another type.
+ * Converts a typed constant to a constant of another type.
*
* op operator which requires conversion
* arg if op is FARG, # of argument
- * tp type in which to convert the constant
+ * tp type to which to convert the constant
* nv new constant
* v old constant
*/
@@ -1879,7 +1879,7 @@ cvtcon(op_t op, int arg, type_t *tp, val_t *nv, val_t *v)
case DOUBLE:
max = DBL_MAX; min = -DBL_MAX; break;
case PTR:
- /* Got already an error because of float --> ptr */
+ /* Already an error because of float --> ptr */
case LDOUBLE:
max = LDBL_MAX; min = -LDBL_MAX; break;
default:
@@ -2448,7 +2448,7 @@ bldcol(tnode_t *ln, tnode_t *rn)
lerror("bldcol() 6");
/*
* XXX For now we simply take the left type. This is
- * probably wrong, if one type contains a functionprototype
+ * probably wrong, if one type contains a function prototype
* and the other one, at the same place, only an old style
* declaration.
*/
@@ -2690,7 +2690,7 @@ fold(tnode_t *tn)
break;
case SHR:
/*
- * The sign must be explizitly extended because
+ * The sign must be explicitly extended because
* shifts of signed values are implementation dependent.
*/
q = ul >> sr;
@@ -3136,7 +3136,7 @@ chkfarg(type_t *ftp, tnode_t *args)
*/
for (i = narg, arg = args; i > n; i--, arg = arg->tn_right) ;
- /* some things which are always not allowd */
+ /* some things which are never allowed */
if ((at = arg->tn_left->tn_type->t_tspec) == VOID) {
/* void expressions may not be arguments, arg #%d */
error(151, n);
@@ -3448,7 +3448,7 @@ chkmisc(tnode_t *tn, int vctx, int tctx, int eqwarn, int fcall, int rvdisc,
if (ln->tn_op == NAME && (reached || rchflg)) {
sc = ln->tn_sym->s_scl;
/*
- * Look if there was a asm statement in one of the
+ * Look if there was an asm statement in one of the
* compound statements we are in. If not, we don't
* print a warning.
*/
@@ -3529,7 +3529,7 @@ chkmisc(tnode_t *tn, int vctx, int tctx, int eqwarn, int fcall, int rvdisc,
/*
* Checks the range of array indices, if possible.
* amper is set if only the address of the element is used. This
- * means that the index is allowd to refere to the first element
+ * means that the index is allowd to refer to the first element
* after the array.
*/
static void
@@ -3645,7 +3645,7 @@ chkcomp(op_t op, tnode_t *ln, tnode_t *rn)
}
/*
- * Takes an expression an returns 0 if this expression can be used
+ * Takes an expression and returns 0 if this expression can be used
* for static initialisation, otherwise -1.
*
* Constant initialisation expressions must be costant or an address