The R Project SVN R

Rev

Rev 25961 | Rev 35489 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 25961 Rev 32873
Line 65... Line 65...
65
    if (length(text) > 0) {
65
    if (length(text) > 0) {
66
	if (num == NA_INTEGER)
66
	if (num == NA_INTEGER)
67
	    num = -1;
67
	    num = -1;
68
	s = R_ParseVector(text, num, &status);
68
	s = R_ParseVector(text, num, &status);
69
	if (status != PARSE_OK)
69
	if (status != PARSE_OK)
70
	    errorcall(call, "parse error");
70
	    errorcall(call, _("parse error"));
71
    }
71
    }
72
    else if (ifile >= 3) {/* file != "" */
72
    else if (ifile >= 3) {/* file != "" */
73
	if (num == NA_INTEGER)
73
	if (num == NA_INTEGER)
74
	    num = -1;
74
	    num = -1;
75
	if(!wasopen)
75
	if(!wasopen)
76
	    if(!con->open(con)) error("cannot open the connection");
76
	    if(!con->open(con)) error(_("cannot open the connection"));
77
	s = R_ParseConn(con, num, &status);
77
	s = R_ParseConn(con, num, &status);
78
	if(!wasopen) con->close(con);
78
	if(!wasopen) con->close(con);
79
	if (status != PARSE_OK)
79
	if (status != PARSE_OK)
80
	    errorcall(call, "syntax error on line %d", R_ParseError);
80
	    errorcall(call, _("syntax error on line %d"), R_ParseError);
81
    }
81
    }
82
    else {
82
    else {
83
	if (num == NA_INTEGER)
83
	if (num == NA_INTEGER)
84
	    num = 1;
84
	    num = 1;
85
	s = R_ParseBuffer(&R_ConsoleIob, num, &status, prompt);
85
	s = R_ParseBuffer(&R_ConsoleIob, num, &status, prompt);
86
	if (status != PARSE_OK)
86
	if (status != PARSE_OK)
87
	    errorcall(call, "parse error");
87
	    errorcall(call, _("parse error"));
88
    }
88
    }
89
    UNPROTECT(2);
89
    UNPROTECT(2);
90
    return s;
90
    return s;
91
}
91
}
92
 
92