SPL to HP C/XL Migration Guide (30231-90001)
2: 2
| | eight characters are ASCII numeric. |
| | |
---------------------------------------------------------------------------------------------
| | |
| Statement labels are identifiers followed | Same as SPL. |
| by colon ("
label
:"). | |
| | |
---------------------------------------------------------------------------------------------
| | |
| A compilation unit is bracketed by the | A compilation unit has no special |
| reserved words BEGIN and END and terminated | delimiters. It consists of declarations |
| with a period (".") | and one or more function definitions. |
| | |
---------------------------------------------------------------------------------------------
| | |
| Compiler commands are denoted by a "$" in | Compiler directives are denoted by a "#" in |
| column 1. | column 1. |
| | |
---------------------------------------------------------------------------------------------
| | |
| A compiler command line is continued to the | A directive line is continued by having "\" |
| next line by having "&" as its last | as the last nonblank. |
| nonblank character. | |
| | |
---------------------------------------------------------------------------------------------
| | |
| Tokens may not be broken across records. | Same as SPL. |
| | |
---------------------------------------------------------------------------------------------
| | |
| Source input is
not
sensitive to case. | Source input
is
case sensitive. (Variable |
| (Variable Var1 is the same as var1.) | Var1 is different from var1.) All HP C/XL |
| | keywords must appear in lowercase. |
| | |
---------------------------------------------------------------------------------------------
Delimiters
Table 2-3. Delimiters
---------------------------------------------------------------------------------------------
| | |
| SPL | HP C/XL Equivalent |
| | |
---------------------------------------------------------------------------------------------
| | |
| Blanks and special characters (other than | Similar, except that underscore, "_", |
| apostophes) act as delimiters to reserved | assumes the role of apostrophe in |
| words and identifiers. Apostrophes, "'", | identifiers and as a nonseparator. That |
| may be used in identifiers. | is, change "'" to "_". |
| | |
---------------------------------------------------------------------------------------------
| | |
| Blanks cannot be embedded in reserved | Same as SPL. |
| words, identifiers, and multicharacter | |
| tokens, such as ":=", "<<", and ">>". | |
| | |
---------------------------------------------------------------------------------------------
Comments
Table 2-4. Comments
---------------------------------------------------------------------------------------------
| | |
| SPL | HP C/XL Equivalent |
| | |
---------------------------------------------------------------------------------------------
| | |
|
comment
: |
comment
: |
| | |
| COMMENT
comment-text
; | /*
comment-text
*/ |
| | |