PR# 13734 Class invariants inherited from ANY not checked

Problem Report Summary
Submitter: prestoat2000
Category: Runtime
Priority: Medium
Date: 2007/12/08
Class: Bug
Severity: Serious
Number: 13734
Release: 6.1.71367
Confidential: No
Status: Analyzed
Responsible: manus_eiffel
Environment: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:1.8.1.5) Gecko/20070719 Firefox/2.0.0.5 Solaris 10 on x86
Synopsis: Class invariants inherited from ANY not checked

Description
Class invariants inherited from ANY are not checked when .ecf file requests
checking of invariants and use_application_options="true" for base library.
Supplied test case redefines {ANY}.conforms_to so that it always returns
False to demonstrate this.

I found this bug after noticing the following line in both plug.c and
interp.c

     if (dtype <= 0) return;         /* ANY does not have invariants */


To Reproduce
Compile with attached files and execute system.  Invariants inherited from
ANY are not checked.
Problem Report Interactions
From:manus_eiffel    Date:2007/12/08    Status: Analyzed    Download   
The reason for it is that in theory `conforms_to' should be frozen and the invariants should always hold anyway. As a result, this code is an optimization to not check ANY's invariant all the time.

I'll make sure that `conforms_to' becomes frozen in ELKS.

From:prestoat2000    Date:2007/12/08    Download   
Attachments for problem report #13734

Attachment: test.e     Size:89
Attachment: test1.e     Size:218
Attachment: test.ecf     Size:952