The R Project SVN R

Rev

Rev 90283 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 90283 Rev 90294
Line 1316... Line 1316...
1316
		break;
1316
		break;
1317
	    }
1317
	    }
1318
	}
1318
	}
1319
	if (havematch == 1) { /* unique partial match */
1319
	if (havematch == 1) { /* unique partial match */
1320
	    if(R_warn_partial_match_dollar) {
1320
	    if(R_warn_partial_match_dollar) {
1321
		const char *st = "";
-
 
1322
		SEXP target = TAG(xmatch);
1321
		SEXP target = TAG(xmatch);
1323
		switch (TYPEOF(target)) {
-
 
1324
		case SYMSXP:
-
 
1325
		    st = CHAR(PRINTNAME(target));
-
 
1326
		    break;
-
 
1327
		case CHARSXP:
-
 
1328
		    st = translateChar(target);
-
 
1329
		    break;
-
 
1330
		}
-
 
1331
		SEXP cond =
1322
		SEXP cond =
1332
		    R_makePartialMatchWarningCondition(call,
1323
		    R_makePartialMatchWarningCondition(call,
1333
						       install(translateChar(input)), 
1324
						       input,
1334
						       install(st));
1325
						       target);
1335
		PROTECT(cond);
1326
		PROTECT(cond);
1336
		R_signalWarningCondition(cond);
1327
		R_signalWarningCondition(cond);
1337
		UNPROTECT(1);
1328
		UNPROTECT(1);
1338
	    }
1329
	    }
1339
	    y = CAR(xmatch);
1330
	    y = CAR(xmatch);
Line 1379... Line 1370...
1379
		break;
1370
		break;
1380
	    }
1371
	    }
1381
	}
1372
	}
1382
	if(havematch == 1) { /* unique partial match */
1373
	if(havematch == 1) { /* unique partial match */
1383
	    if(R_warn_partial_match_dollar) {
1374
	    if(R_warn_partial_match_dollar) {
1384
		const char *st = "";
-
 
1385
		SEXP target = STRING_ELT(nlist, imatch);
1375
		SEXP target = STRING_ELT(nlist, imatch);
1386
		switch (TYPEOF(target)) {
-
 
1387
		case SYMSXP:
-
 
1388
		    st = CHAR(PRINTNAME(target));
-
 
1389
		    break;
-
 
1390
		case CHARSXP:
-
 
1391
		    st = translateChar(target);
-
 
1392
		    break;
-
 
1393
		}
-
 
1394
		SEXP cond =
1376
		SEXP cond =
1395
		    R_makePartialMatchWarningCondition(call,
1377
		    R_makePartialMatchWarningCondition(call,
1396
						       install(translateChar(input)), 
1378
						       input,
1397
						       install(st));
1379
						       target);
1398
		PROTECT(cond);
1380
		PROTECT(cond);
1399
		R_signalWarningCondition(cond);
1381
		R_signalWarningCondition(cond);
1400
		UNPROTECT(1);
1382
		UNPROTECT(1);
1401
	    }
1383
	    }
1402
	    y = VECTOR_ELT(x, imatch);
1384
	    y = VECTOR_ELT(x, imatch);