Thread View: net.lang.ada
1 messages
1 total messages
Started by Doug Bryan
Thu, 09 Oct 1986 18:11
predefined operations
Author: Doug Bryan
Date: Thu, 09 Oct 1986 18:11
Date: Thu, 09 Oct 1986 18:11
21 lines
1342 bytes
1342 bytes
Since we are still on the subject of predefined operations, I may as well throw out the execption to the rule: procedure Not_Immediately_After is type F1 is delta 1.0/16 range 0.0 .. 1_000.0; type F2 is delta 2#0.1#E-3 range 0.0 .. 1_000.0; X : F1 := 1.0; Y : F2 := 2.0; begin X := F1 (Standard."*"(X, Y)); end Not_Immediately_After; The reason this works is that any two fixed point operands may be multiplied. Since the two fixed point types may be declared in different, non-overlapping scopes, the only deterministic place to define "*" is in Standard. The result of this operation is of the type universal_fixed and is never implicitly converted to a name type (like universal_integer and universal_real are). doug -------
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads