CompileErrors/C0029: Difference between revisions

From Compost Wiki
Jump to navigation Jump to search
Danielr (talk | contribs)
No edit summary
Danielr (talk | contribs)
No edit summary
 
Line 1: Line 1:
{{CompileError
{{CompileError
|errortext = C0029 - Optimizer: Skipping constant NUM# because optimizing it might change output formatting
|errortext = C0029 - Optimizer: Skipping constant NUM# because optimizing it might change output formatting
|description = C0029 is issued when a NUM# could be optimized into a constant, but it would affect the output if NUM# were formatted differently than the numeric constant.
|description = C0029 is issued when a NUM# could be optimized into a constant, but it would affect the output if NUM# were formatted differently than the numeric constant.  When C0029 is issued, the optimization is skipped, so that the output is still formatted by NUM#.
|exampletext = The result of NUM# is output to the stream after being formatted.
|exampletext = The result of NUM# is output to the stream after being formatted.
|examplecode = FORMAT(NUM#, 'MyFormat')
|examplecode = FORMAT(NUM#, 'MyFormat')

Latest revision as of 18:48, 12 May 2015

C0029 - Optimizer: Skipping constant NUM# because optimizing it might change output formatting

Description

C0029 is issued when a NUM# could be optimized into a constant, but it would affect the output if NUM# were formatted differently than the numeric constant. When C0029 is issued, the optimization is skipped, so that the output is still formatted by NUM#.

Example of Cause

The result of NUM# is output to the stream after being formatted.

FORMAT(NUM#, 'MyFormat')

NUM#('1.0') { C0029 - Optimizer: Skipping constant NUM# because optimizing it might change output formatting }

Resolution

Replace the NUM# command with a constant or literal. Use the Output command if you need to format a constant.

'1.0' { No error }