<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/20177" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2016-06-16T07:17:34-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/20177</id>

		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-06-16T07:17:34-04:00</updated>

		<published>2016-06-16T07:17:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105179#p105179</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105179#p105179"/>
		<title type="html"><![CDATA[upvrar in namespace]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105179#p105179"><![CDATA[
Why can't use upvar on a variable that is defined outside the proc that is in a namespace?<br><br>I tried something like:<div class="codebox"><p>Code: </p><pre><code>namespace eval blah {set foo 1proc moo {x} {upvar #0 $x varputs $var}}</code></pre></div>and other ways but all fail. From what I read a <em class="text-italics">upvar #0</em> should be the equivalent of a <em class="text-italics">global</em> call but that fails as well, meaning the <em class="text-italics">var</em> variable isn't created.<br><br>If I take the code outside the <em class="text-italics">namespace</em> then it's working as expected. What am I doing wrong?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Jun 16, 2016 7:17 am</p><hr />
]]></content>
	</entry>
	</feed>
