HPlogo System Debug Reference Manual: HP 3000 MPE/iX Computer Systems > Chapter 8 System Debug Standard Functions

func trans

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Index

Coerces an expression into a TRANS logical code pointer (LCPTR).

Syntax

   trans (value)  


Formal Declaration

   trans:trans (value:any) 

Parameters

value

An expression to be coerced. All types are acceptable.

Table 8-17 Derivation of the TRANS Bit Pattern

Parameter TypeAction
BOOL0.1 if TRUE, 0.0 if FALSE.

U16

U32

SPTR

Set the SID part to zero. Right justify the original value in the low-order 32 bits of the offset part with zero fill.

S16

S32

S64

Set the SID part to zero. Right justify the original value in the low-order 32 bits of the offset part with sign extension.
LONG ClassTransfer both parts of the address unchanged.

EADDR

SADDR

Transfer the SID part unchanged. Transfer the low-order 32 bits of the offset part.
STRTransfer the ASCII bit pattern for the last eight characters in the string. Strings shorter than eight characters are treated as if they were extended on the left with nulls.

 

Examples

   %cmdebug > wl trans(12.304)

   TRANS %12.304


Coerce the simple long pointer into a TRANS logical code pointer.

   %cmdebug > wl trans(sys(24.630))

   TRANS %24.630

The coercion simply changes the type. Note that no complicated conversion or range checking is performed.

Limitations, Restrictions

none

Feedback to webmaster