[Rd] documentation bug in readline() (PR#685)

pperkins@ucsd.edu pperkins@ucsd.edu
Sat, 7 Oct 2000 04:09:00 +0200 (MET DST)

This is a multi-part message in MIME format.
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

hi -

the documentation for readline() should reflect the fact that the
prompt= arg is truncated to CONSOLE_PROMPT_SIZE chars, currently defined 
as 32 in src/main/scan.c.  assuming this is the correct behavior, an
updated copy of readline.Rd is attached.

--please do not edit the information below--

 platform = powerpc-unknown-linux-gnu
 arch = powerpc
 os = linux-gnu
 system = powerpc, linux-gnu
 status = 
 major = 1
 minor = 1.1
 year = 2000
 month = August
 day = 15
 language = R

Search Path:
 .GlobalEnv, file:/home/peter/R/Home.RData, package:local,
package:distns, Autoloads, package:base
Content-Type: text/plain; charset=us-ascii;
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;

\title{Read a Line from the Terminal}
  \item{prompt}{the string printed when prompting the user for input.
  This will be truncated to a maximum allowed length, currently 32 chars.
  Should usually end with a space \code{" "}.}
  \code{readline} reads a line from the terminal, returning it as a
  character string.
fun <- function() {
  ANSWER <- readline("Are you a satisfied R user? ")
  if (substr(ANSWER, 1, 1) == "n")
    cat("This is impossible.  YOU LIED!\n")
    cat("I knew it.\n")


r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch