SPL to HP C/XL Migration Guide (30231-90001)

8- 14
Local Pointer Declarations
See "POINTER Declaration" for further details.
Standard Local Pointers.
Table 8-15. Standard Local Pointers
---------------------------------------------------------------------------------------------
| | |
| SPL | HP C/XL Equivalent |
| | |
---------------------------------------------------------------------------------------------
| | |
|
standard-local-pointer-declaration
: |
pointer-declaration
: |
| | |
| [
type
] POINTER
ptr-decl
[,...] ; | [
type
]
ptr-decl
[,...] ; |
| | |
| | |
|
ptr-decl
: |
ptr-decl
: |
| | |
| 1a.
ptr-id
| 1a. *
ptr-id
|
| | |
| 1b.
ptr-id
:= @
ref-id
| 1ba.*
ptr-id
=
ref-id
|
| | |
| 1c.
ptr-id
:= @
ref-id
(
index
) | 1bv.*
ptr-id
= &
ref-id
|
| | |
| 2a.
ptr-id
=
ref-id
| 1c.*
ptr-id
= &
ref-id "
[
" index "
]
"
|
| | |
| 2b.
ptr-id
=
ref-id sign offset
| |
| | 1ba:
ref-id
is an array or pointer id. |
| 3a.
ptr-id
=
register
| |
| | 1bv:
ref-id
is a simple variable. |
| 3b.
ptr-id
=
register sign offset
| |
| | |
| 4.
ptr-id
=
offset
| |
| | |
---------------------------------------------------------------------------------------------
| | |
| Default type: LOGICAL | Default type: int (= long int) |
| | |
---------------------------------------------------------------------------------------------
| | |
| Pointers are 16-bit values containing | Pointers are 32-bit values containing |
| DB-relative addresses. | standard MPE XL addresses. |
| | |
| | Overlays of pointers and other data types |
| | must be recoded. |
| | |
---------------------------------------------------------------------------------------------
OWN Local Pointers.
Table 8-16. OWN Local Pointers
---------------------------------------------------------------------------------------------
| | |
| SPL | HP C/XL Equivalent |
| | |
---------------------------------------------------------------------------------------------
| | |
|
own-local-pointer
: |
static-local-pointer
: |
| | |
| OWN [
type
] POINTER
ptr-decl
[,...] ; | static [
type
]
ptr-decl
[,...] ; |
| | |
| | |
|
ptr-decl
: |
ptr-decl
: |
| | |
|
ptr-id
| *
ptr-id
|
| | |
---------------------------------------------------------------------------------------------
| | |