<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Debugging PHP with Magic Constants</title>
	<atom:link href="http://www.ebrueggeman.com/blog/php/debugging_php_constants/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ebrueggeman.com/blog/php/debugging_php_constants/</link>
	<description>Tips and Tricks for Web Developers</description>
	<pubDate>Wed, 03 Dec 2008 23:21:19 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
		<item>
		<title>By: Cypher</title>
		<link>http://www.ebrueggeman.com/blog/php/debugging_php_constants/#comment-28</link>
		<dc:creator>Cypher</dc:creator>
		<pubDate>Tue, 02 Sep 2008 13:44:11 +0000</pubDate>
		<guid isPermaLink="false">http://www.ebrueggeman.com/blog/php/debugging_php_constants/#comment-28</guid>
		<description>You are saying "The constant __FUNCTION__ will return the same method information when a function is inside of a class, so you can just use __FUNCTION__ instead of __METHOD__."

It's not true. Let's say you have class like this:

class MyClass
{
    function myFunc()
    {
        throw new Exception(__FUNCTION__);
    }

    function myMeth()
    {
        throw new Exception(__METHOD__);
    }
}

The result you will get by calling MyClass-&#62;myFunc will be "myFunc" whereas the result from myMeth will be "MyClass::myMeth".</description>
		<content:encoded><![CDATA[<p>You are saying &#8220;The constant __FUNCTION__ will return the same method information when a function is inside of a class, so you can just use __FUNCTION__ instead of __METHOD__.&#8221;</p>
<p>It&#8217;s not true. Let&#8217;s say you have class like this:</p>
<p>class MyClass<br />
{<br />
    function myFunc()<br />
    {<br />
        throw new Exception(__FUNCTION__);<br />
    }</p>
<p>    function myMeth()<br />
    {<br />
        throw new Exception(__METHOD__);<br />
    }<br />
}</p>
<p>The result you will get by calling MyClass-&gt;myFunc will be &#8220;myFunc&#8221; whereas the result from myMeth will be &#8220;MyClass::myMeth&#8221;.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
