<?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>error: #28 expression must have a constant value</title><link>https://community.arm.com/developer/tools-software/tools/f/keil-forum/20457/error-28-expression-must-have-a-constant-value</link><description> I have used the trail and full Uvision3 ARM compiler. 
The following code produces the error 
&amp;#39;expression must have a constant value&amp;#39; at the indicated position below. 
The same code compiled on about 5 other different compilers(microchip, borland, microsoft</description><dc:language>en-US</dc:language><generator>Telligent Community 10</generator><item><title>RE: error: #28 expression must have a constant value</title><link>https://community.arm.com/thread/46488?ContentTypeID=1</link><pubDate>Mon, 31 Jul 2006 00:50:48 GMT</pubDate><guid isPermaLink="false">dd9e70c8-6d3c-4c71-b136-2456382a7b5c:54d5ea6e-cdbc-404b-af13-77161b536918</guid><dc:creator>Keil Software Support Intl.</dc:creator><description>&lt;p&gt;You are defining &lt;b&gt;Profile&lt;/b&gt; as an automatic variable that is located on stack.  Therefore the address of this variable cannot be represented as a constant.&lt;br /&gt;
&lt;br /&gt;
You have two options:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
  &lt;li&gt;use the static attribute:&lt;br /&gt;
  &lt;pre&gt;static EDIT Profile=...&lt;/pre&gt;&lt;/li&gt;
  &lt;li&gt;define the variable &lt;b&gt;Profile&lt;/b&gt; outside of the function &lt;b&gt;main&lt;/b&gt;.&lt;/li&gt;
&lt;/ul&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>