Skip to content

Commit 1ca6aba

Browse files
author
maechler
committed
fix PR#18904 (typos in /methods/)
git-svn-id: https://svn.r-project.org/R/trunk@88267 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent bb11fef commit 1ca6aba

18 files changed

+28
-28
lines changed

src/library/methods/R/BasicClasses.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@
518518
}
519519

520520
## .OldClassesList is a purely heuristic list of known old-style classes, with emphasis
521-
## on old-style class inheritiance. Used in .InitBasicClasses to call setOldClass for
521+
## on old-style class inheritance. Used in .InitBasicClasses to call setOldClass for
522522
## each known class pattern.
523523
## .OldClassesPrototypes is a list of S3 classes for which prototype
524524
## objects are known & reasonable.

src/library/methods/R/Methods.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1343,7 +1343,7 @@ implicitGeneric <- function(...) NULL
13431343
### Add the named function to the table of implicit generics in environment where.
13441344
###
13451345
### If there is a generic function of this name, it is saved to the
1346-
### table. This is the reccomended approach and is required if you
1346+
### table. This is the recommended approach and is required if you
13471347
### want the saved generic to include any non-default methods.
13481348
###
13491349
{

src/library/methods/R/MethodsList.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ insertMethod <-
144144
length(sigArgs) <- n
145145
if(is.na(match(nextArg, sigArgs))) {
146146
n <- match(nextArg, args) - n
147-
if(is.na(n)) { ## not in args eitiher
147+
if(is.na(n)) { ## not in args either
148148
n <- 1
149149
args <- c(args, nextArg)
150150
}

src/library/methods/R/MethodsListClass.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ loadMethod <- function(method, fname, envir) method
9292
assign("asMethodDefinition",
9393
function(def, signature = list(.anyClassName), sealed = FALSE, fdef = def) {
9494
## primitives can't take slots, but they are only legal as default methods
95-
## and the code will just have to accomodate them in that role, w/o the
95+
## and the code will just have to accommodate them in that role, w/o the
9696
## MethodDefinition information.
9797
## NULL is a valid def, used to remove methods.
9898
switch(typeof(def),

src/library/methods/R/RClassUtils.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ superClassDepth <-
419419
more <- Recall(superClass, soFar)
420420
whatMore <- more$label
421421
if(!all(is.na(match(whatMore, soFar)))) {
422-
## elminate classes reachable by more than one path
422+
## eliminate classes reachable by more than one path
423423
## (This is allowed in the model, however)
424424
ok <- is.na(match(whatMore, soFar))
425425
more$depth <- more$depth[ok]
@@ -1229,7 +1229,7 @@ completeSubclasses <-
12291229
what2 <- what[affected]
12301230
dups <- unique(what2[duplicated(what2)])
12311231
if(length(dups) == 0) {
1232-
## eliminating conditonal relations removed duplicates
1232+
## eliminating conditional relations removed duplicates
12331233
if(length(conflicts) > 0)
12341234
attr(ext, "conflicts") <- unique(c(conflicts, attr(ext, "conflicts")))
12351235
return(ext)
@@ -2032,7 +2032,7 @@ assign("#HAS_DUPLICATE_CLASS_NAMES", FALSE, envir = .classTable)
20322032
i <- match(newpkg, names(prev))
20332033
if(!is.na(i))
20342034
prev[[i]] <- NULL
2035-
else # we might warn about unchaching more than once
2035+
else # we might warn about uncaching more than once
20362036
return()
20372037
if(length(prev) == 0L)
20382038
return(remove(list = name, envir = .classTable))

src/library/methods/R/RMethodUtils.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -577,7 +577,7 @@ getGeneric <-
577577
i <- match(newpkg, names(prev))
578578
if(!is.na(i))
579579
prev[[i]] <- NULL
580-
else # we might warn about unchaching more than once
580+
else # we might warn about uncaching more than once
581581
return()
582582
if(length(prev) == 0L)
583583
return(remove(list = name, envir = table))
@@ -1430,7 +1430,7 @@ metaNameUndo <- function(strings, prefix, searchForm = FALSE)
14301430

14311431
.identC <- function(c1 = NULL, c2 = NULL)
14321432
{
1433-
## are the two objects identical class or genric function string names?
1433+
## are the two objects identical class or generic function string names?
14341434
.Call(C_R_identC, c1, c2)
14351435
}
14361436

@@ -1451,7 +1451,7 @@ matchDefaults <- function(method, generic)
14511451
garg <- gargs[[arg]]
14521452
if(missing(marg) && !missing(garg)) {
14531453
changes <- TRUE
1454-
margs[arg] <- gargs[arg] # NOT [[]], which woud fail for NULL element
1454+
margs[arg] <- gargs[arg] # NOT [[]], which would fail for NULL element
14551455
}
14561456
}
14571457
if(changes)
@@ -1712,7 +1712,7 @@ utils::globalVariables(c(".MTable", ".AllMTable", ".dotsCall"))
17121712

17131713
if(FALSE) {
17141714
## Defined but not currently used:
1715-
## utilitity to test well-defined classes in signature,
1715+
## utility to test well-defined classes in signature,
17161716
## for setMethod(), setAs() [etc.?], the result to be
17171717
## assigned in package where=
17181718
## Returns a list of signature, messages and level of error

src/library/methods/R/is.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ setIs <-
196196
classDef2@prototype <-
197197
if(classDef@virtual)
198198
classDef@prototype
199-
else # new(), but without intialize(), which may require an arg.
199+
else # new(), but without initialize(), which may require an arg.
200200
.Call(C_new_object, classDef)
201201
}
202202
}

src/library/methods/R/methods-defunct.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
## Defunct in 4.5.0
4040
MethodsListSelect <-
4141
## select the element of a MethodsList object corresponding to the
42-
## actual arguments (as defined in the suppled environment),
42+
## actual arguments (as defined in the supplied environment),
4343
## and return the object, extended to include that method if necessary.
4444
##
4545
## Works recursively. At each level finds an argument name from the current `mlist'

src/library/methods/R/methodsTable.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,7 @@
685685
}
686686

687687
.newSignature <- function(classes, names) {
688-
## a simple version to deal with boostrapping stage, used in new() etc
688+
## a simple version to deal with bootstrapping stage, used in new() etc
689689
n <- min(length(classes), length(names))
690690
i <- seq_len(n)
691691
## a corresponding set of package names
@@ -1124,7 +1124,7 @@ useMTable <- function(onOff = NA)
11241124
f
11251125
}))
11261126
}
1127-
## now the next generations recusively
1127+
## now the next generations recursively
11281128
if(length(funs) > start) {
11291129
nmore <- length(funs) - start
11301130
more <- Recall(funs[(start+1):length(funs)])

src/library/methods/R/oldClass.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ S3Class <- function(object) {
299299
object
300300
}
301301

302-
## rename a class definition: needs to change if any additional occurences of class
302+
## rename a class definition: needs to change if any additional occurrences of class
303303
## name are added, other than the className slot and the super/sub class names
304304
## in the contains, subclasses slots respectively.
305305
.renameClassDef <- function(def, className) {

0 commit comments

Comments
 (0)