View | Details | Raw Unified | Return to bug 16490 | Differences between
and this patch

Collapse All | Expand All

(-)src/library/base/R/namespace.R (-8 / +6 lines)
Lines 1468-1479 Link Here
1468
1468
1469
.mergeImportMethods <- function(impenv, expenv, metaname)
1469
.mergeImportMethods <- function(impenv, expenv, metaname)
1470
{
1470
{
1471
    expMethods <- get(metaname, envir = expenv)
1471
    expMethods <- expenv[[metaname]] # known to exist by caller
1472
    if(!is.null(impMethods <- get0(metaname, envir = impenv, inherits = FALSE))) {
1472
    impMethods <- impenv[[metaname]]
1473
	assign(metaname,
1473
    if(!is.null(impMethods)) {
1474
	       methods:::.mergeMethodsTable2(impMethods,
1474
	impenv[[metaname]] <-  methods:::.mergeMethodsTable2(impMethods,expMethods, expenv, metaname)
1475
					     expMethods, expenv, metaname),
1476
	       envir = impenv)
1477
	impMethods
1478
    } ## else NULL
1479
}
1475
}
1476
    impMethods # Sometimes NULL
1477
}

Return to bug 16490