[fpc-devel] Dangerous optimization in CASE..OF
Jonas Maebe
jonas at freepascal.org
Sun Jul 2 18:28:39 CEST 2017
On 02/07/17 18:26, Ondrej Pokorny wrote:
> On 02.07.2017 18:20, Jonas Maebe wrote:
>> Range checking code is generated for operations involving enums if,
>> according to the type system, the enum can be out of range. Just like
>> with integer sub-range types.
>
> Allow me a stupid question: how to convert an integer to enum with range
> checking?
The current possibilities and possibly improvements have been mentioned
elsewhere in this thread already
* http://lists.freepascal.org/pipermail/fpc-devel/2017-July/038013.html
* http://lists.freepascal.org/pipermail/fpc-devel/2017-July/038014.html
Jonas
More information about the fpc-devel
mailing list