NETJVM 

Data Types in Managed COBOL

COBOL provides predefined usages corresponding to many of the most commonly used managed code types. These names can be used when declaring a data item, and anywhere a type specifier is expected - see Specifying Type Names. For example:

    01 anInteger binary-long.

Predefined Managed Types

Managed COBOL .NET type JVM type C# keyword Description
Integer types:
binary-char System.SByte byte sbyte An 8-bit signed integer

Not CLS-compliant

binary-char unsigned System.Byte byte An 8-bit unsigned integer
binary-short System.Int16 short short A 16-bit signed integer

Not CLS-compliant

binary-short unsigned System.UInt16 ushort A 16-bit unsigned integer
binary-long System.Int32 int int A 32-bit signed integer
binary-long unsigned System.UInt32 uint A 32-bit unsigned integer

Not CLS-compliant.

binary-double System.Int64 long long A 64-bit signed integer
binary-double unsigned System.UInt64 ulong A 64-bit unsigned integer

Not CLS-compliant

Floating point types:
float-short System.Single float float A single-precision (32-bit) floating-point number
float-long System.Double double double A double-precision (64-bit) floating-point number
Logical types:
condition-value System.Boolean boolean bool A boolean value (true or false)
Other types:
character System.Char char char A unicode (16-bit) character
decimal System.Decimal