My program doesn't have bugs. It just develops random features.

Difference between revisions of "Compiler issues"

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
(can someone fix this for me, I dunno how)
m (Parsing Issues: Fixed format)
Line 5: Line 5:
 
<br>
 
<br>
 
:Having an end of multi-line comment proceeded by a line comment on the same line.
 
:Having an end of multi-line comment proceeded by a line comment on the same line.
 
+
{{CorrectWrong|<uscript>
<center>
+
/* if(!bUseForVehicles)  
{| border="0" cellspacing="0"
+
        return Super.DamageTaken(Enemy, Injured);
|colspan="2" align="center"|
+
    else{//Branch4: Do vehicle code here, optimized?}
'''Example'''
+
*/</uscript><uscript>/*local int LogInitHealth;*/ /*, LogDamage, LogConversion;*/
|-
+
</uscript>|<uscript>/* if(!bUseForVehicles)  
|style="background-color:#ff0000;" width="384" align="center"|
+
        return Super.DamageTaken(Enemy, Injured);
Wrong
+
    else{//Branch4: Do vehicle code here, optimized?}*/</uscript><uscript>/*local int LogInitHealth;*//*, LogDamage, LogConversion;*/
|style="background-color:#00ff00;" width="384" align="center"|
+
</uscript>}}
Correct
+
 
+
|-
+
|align="center"|
+
<uscript>
+
/* if(!bUseForVehicles) return Super.DamageTaken(Enemy, Injured);
+
else{//Branch4: Do vehicle code here, optimized?} */
+
</uscript>
+
 
+
|align="center"|
+
<uscript>
+
/* if(!bUseForVehicles) return Super.DamageTaken(Enemy, Injured);
+
else{//Branch4: Do vehicle code here, optimized?}
+
*/
+
</uscript>
+
 
+
|-
+
|align="center"|
+
<uscript>
+
/*local int LogInitHealth;*//*, LogDamage, LogConversion;*/
+
</uscript>
+
 
+
|align="center"|
+
<uscript>
+
/*local int LogInitHealth;*/ /*, LogDamage, LogConversion;*/
+
</uscript>
+
|-}
+
</center>
+
  
 
'''DefaultProperties''' ''Issues related to the [[defaultproperties]] block''
 
'''DefaultProperties''' ''Issues related to the [[defaultproperties]] block''
Line 47: Line 19:
 
:Placing a { on the same line of the defaultproperties declaration will cause the parser to skip the defaultproperties block thus :all of your default values will not be compiled, to get around this is easy just place the { on the next line!.
 
:Placing a { on the same line of the defaultproperties declaration will cause the parser to skip the defaultproperties block thus :all of your default values will not be compiled, to get around this is easy just place the { on the next line!.
  
<center>
+
{{CorrectWrong|<uscript>
{| border="0" cellspacing="0"
+
|colspan="2" align="center"|
+
'''Example'''
+
|-
+
|style="background-color:#ff0000;" width="256" align="center"|
+
Wrong
+
|style="background-color:#00ff00;" width="256" align="center"|
+
Correct
+
 
+
|-
+
|align="center"|
+
<uscript>
+
 
defaultproperties{
 
defaultproperties{
}
+
}</uscript>|<uscript>
</uscript>
+
 
+
|align="center"|
+
<uscript>
+
 
defaultproperties
 
defaultproperties
 
{
 
{
}
+
}</uscript>}}
</uscript>
+
|-}
+
</center>
+

Revision as of 19:30, 6 September 2010

Like any other compiler there are issues with the parsing therefor this page exists to mention those common issues and how to get around them.

Parsing Issues

Comment Issues related to the comments

Having an end of multi-line comment proceeded by a line comment on the same line.
Correct and Wrong example

DefaultProperties Issues related to the defaultproperties block

Placing a { on the same line of the defaultproperties declaration will cause the parser to skip the defaultproperties block thus :all of your default values will not be compiled, to get around this is easy just place the { on the next line!.
Correct and Wrong example