From homerhanumat at gmail.com  Mon Sep 18 19:06:53 2017
From: homerhanumat at gmail.com (Homer White)
Date: Mon, 18 Sep 2017 13:06:53 -0400
Subject: [Rd] issue with promises for time parameter of rep()
Message-ID: <CAPYa3vTG0zEMoJonD1yEc8+9=yZ-2Lnp8FLG8U1o4iGT+d9ktg@mail.gmail.com>

Greetings,

The following is based on a question I raised on Stackoverflow:

https://stackoverflow.com/questions/46280120/calling-printls-str-in-function-affect-behavior-of-rep/46283979#46283979

Start a new R session with an empty Global Env.  Then define:

f <- function(n) {
  print(ls.str())
  rep("hello", times = n)
}

Now run:

f(x)

Instead of getting the expected "object 'x' not found" error, you get:

n : <missing>[1] "hello"

It was suggested that I file the issue here as a possible bug.


Regards,

Homer

	[[alternative HTML version deleted]]



[Rd] issue with promises for time parameter of rep()
Homer White