Lugaru's Epsilon
Programmer's
Editor 14.04

Context:
Epsilon User's Manual and Reference
   . . .
   Introduction to EEL
      Epsilon Extension Language Features
      EEL Tutorial
   Epsilon Extension Language
      . . .
      Initialization
      Statements
      Conversions
      Operator Grouping
      Order of Evaluation
      . . .
   Primitives and EEL Subroutines
      Buffer Primitives
      Display Primitives
      File Primitives
      . . .
      Defining Language Modes
   . . .

Previous   Up    Next
Block  Epsilon Extension Language   Operator Grouping


Epsilon User's Manual and Reference > Epsilon Extension Language >

Conversions

When a value of a certain type is changed to another type, a conversion occurs.

When a number of some type is converted to another type of number, if the number can be represented in the latter type its value will be unchanged. All possible characters can be represented as ints or short ints, and all short ints can be represented as ints, so these conversions yield unchanged values.

Technically, Epsilon will sign-extend a short int to convert it to an int, but will pad a character with zero bits on the left to convert it to an int or short int. Converting a number of some type to a number of a shorter type is always done by dropping bits.

A pointer may not be converted to an int, or vice versa, except for function pointers. The latter may be converted to a short int, or to any type that a short int may be converted to. A pointer to one type may be converted to a pointer to another type, as long as neither of them is a function pointer.

All operators that take numbers as operands will take any size numbers (characters, short ints, or ints). The operands will be converted to int if they aren't already ints. Operators that yield numbers always produce ints.



Previous   Up    Next
Block  Epsilon Extension Language   Operator Grouping


Lugaru Epsilon Programmer's Editor 14.04 manual. Copyright (C) 1984, 2021 by Lugaru Software Ltd. All rights reserved.