<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.arm.com/utility/feedstylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Using enumeration constants with uVision3</title><link>https://community.arm.com/developer/tools-software/tools/f/keil-forum/19116/using-enumeration-constants-with-uvision3</link><description> The argument I have always heard for using enumerations to 
define constants in C is that it allows the tool chain to 
pass the symbols to one&amp;#39;s debug environment. According to 
earlier discussions I have seen on this forum, that is not 
true of any</description><dc:language>en-US</dc:language><generator>Telligent Community 10</generator><item><title>RE: Using enumeration constants with uVision3</title><link>https://community.arm.com/thread/46125?ContentTypeID=1</link><pubDate>Tue, 23 May 2006 12:26:19 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:5d93ab88-909e-4285-b48c-a5fdf46e37c0</guid><dc:creator>Andy Neil</dc:creator><description>&lt;p&gt;&lt;i&gt;&amp;quot;According to earlier discussions I have seen on this forum&amp;quot;&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
Like these:&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://www.keil.com/forum/docs/thread6863.asp"&gt;http://www.keil.com/forum/docs/thread6863.asp&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://www.keil.com/forum/docs/thread7149.asp"&gt;http://www.keil.com/forum/docs/thread7149.asp&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Using enumeration constants with uVision3</title><link>https://community.arm.com/thread/46121?ContentTypeID=1</link><pubDate>Tue, 23 May 2006 10:28:01 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:ae461df1-cfa7-43b5-ad99-b2397dcd7e7f</guid><dc:creator>Andy Neil</dc:creator><description>&lt;p&gt;&lt;i&gt;&amp;quot;The argument I have always heard for using enumerations to define constants in C is that it allows the tool chain to pass the symbols to one&amp;#39;s debug environment.&amp;quot;&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
The key word there is &lt;i&gt;&amp;quot;allows&amp;quot;&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;&amp;quot;According to earlier discussions I have seen on this forum, that is not true of any of the C51 tools.&amp;quot;&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
C51 does not take advantage of the opportunity.  :-(&lt;br /&gt;
&lt;br /&gt;
You could always hard-code your enumeration values:&lt;pre&gt;typedef enum
{
   IL = 0,
   OH = 1,
   WI = 2,
   IN = 3
} STATE;&lt;/pre&gt;Which means that you don&amp;#39;t throw the entire enum baby out with the #define bathwater...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>