.
D 2002-05-22T16:44:48
J assignee msofer
J cmimetype text/plain
J comment The\sdocumentation\sof\n\nnamespace\sforget\s?pattern\s...?\n\nclaims\sthat\seach\s"pattern"\smust\sbe\sa\squalified\nname.\s\sThat\sis,\sit\smust\scontain\sa\s"::".\s\sIt\sfurther\nclaims\sthat\severything\sto\sthe\sleft\sof\sthe\srightmost\n"::"\smust\sbe\sa\sliteral\sname\sof\san\sexporting\snamespace,\nwhile\severything\sto\sthe\sright\sof\sit\scan\sbe\sa\spattern\nfor\smatching\sagainst\sexported\scommands\sof\sthat\nnamespace.\n\nIn\sfact,\ssimple\snames\sare\spermitted\sas\sarguments\nto\s[namespace\sforget]\sand\sthat\scan\sbe\squite\nuseful.\n\n\s\snamespace\seval\simporter\s{\nnamespace\simport\s::exporter::foo\nnamespace\sforget\sfoo\n\s\s}\n\nwill\swork\sfine\sto\sundo\sthe\simport.\s\sIn\sthis\sexample,\nit\swould\sbe\sjust\sas\seasy\sto\sexplicitly\srepeat\n\nnamespace\sforget\s::exporter::foo\n\nbut\sconsider\sthe\scase\swhere\sthe\sexporting\snamespace\nis\sactually\san\sargument\spassed\sinto\sa\sproc,\sand\s\nthe\s[namespace\sforget]\scomes\sat\sa\slater\stime.\s\sIt\nwould\sbe\sa\sreal\spain\sto\shave\sto\sstore\swhich\sexporting\nnamespace\sthe\scommand\swas\simported\sfrom,\sjust\sso\syou\ncould\ssuccessfully\s[namespace\sforget]\sit\slater.\n\n(Hmmm...\sI\sguess\sit's\snot\sso\sbad,\sbecuase\n\nnamespace\sforget\s[namespace\sorigin\sfoo]\n\nshould\salways\swork,\sbut\swhy\sthe\sextra\sscoping\sif\nit's\snot\sreally\snecessary?)\n\nAnyhow,\sthe\ssimple\scase\sdoes\swork,\sso\sthat\nshould\sbe\sdocumented.\n\nIt\sappears\sit\swill\seven\swork\swith\sa\s[rename]d\nimported\scommand:\n\nnamespace\seval\simporter\s{\n\s\s\s\snamespace\simport\s::exporter::foo\n\s\s\s\srename\sfoo\sbar\n\s\s\s\snamespace\sforget\sbar\n}\n\nSomeone\smore\sfamiliar\swith\sthe\sinternals\sof\s\n[namespace]\sthan\sI\sam\sshould\supdate\sthe\sdocs,\sso\nthe\sexact\srequirements\sand\scapabilities\scan\sbe\ndocumented\scorrectly.
J foundin obsolete:\s8.4a5
J priority 5\sMedium
J resolution None
J status Open
J submitter dgp
J subsystem 21.\s[namespace]
J title incorrect\s[namespace\sforget]\sdocs
J type Bug
K 559268ffffffffffffffffffffffffffffffffff
U dgp
Z eefbd836b8d49215d2e7cd45135349a3