MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Bug, quirk or expected behavior of Slot[]?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg101759] Bug, quirk or expected behavior of Slot[]?
  • From: Salvatore Mangano <smangano at into-technology.com>
  • Date: Thu, 16 Jul 2009 08:19:30 -0400 (EDT)

Someone on the "Linked In" Mathematica User group pointed this out to me:


In[26]:= Clear[y]
Function[Module[{y=0},#===y]][y]
Function[Module[{y=0},#1===y]][y]
Function[t,Module[{y=0},t===y]][y]

Out[27]= True
Out[28]= True
Out[29]= False

It leads me to believe # is more like a placeholder for macro-like substitution than a formal parameter like t.

Thoughts?


  • Prev by Date: CityData is still dead here
  • Next by Date: Re: CityData seems to be dead.
  • Previous by thread: CityData is still dead here
  • Next by thread: Re: Bug, quirk or expected behavior of Slot[]?