PR# 19639 Segmentation violation for unknown reason
Problem Report Summary
Submitter: rosivaldo
Category: Compiler
Priority: Low
Date: 2020/04/24
Class: Bug
Severity: Critical
Number: 19639
Release: 19.12.10.3842
Confidential: No
Status: Open
Responsible:
Environment: win64
Synopsis: Segmentation violation for unknown reason
Description
The code below gets a Segmentation violation at {STI_INTEGER}.one postcondition tagged as "definition" (from deferred {STS_REAL}.one). Forgive the somewhat big amount of code inside sv.zip. The error vanishes when some elements of the code are removed, and I could not figure out which code I could remove and still keep the error popping up. The code sent is already a heavily stripped one. Thanks in advance. class APPLICATION inherit ARGUMENTS_32 create make feature {NONE} make local i: STI_INTEGER do print (i.One) print ('%N') end end One: STI_INTEGER -- Flat view require -- from STS_COMPLEX True once Result := create {STI_INTEGER}.make (1) ensure -- from STS_COMPLEX real: Result.identity.real_equals (identity.One) imaginary: Result.Zero.real_equals (Zero.Zero) ensure then -- from STS_REAL definition: Result.same_value (Result.real_value, 1.to_real) -- <=== Segmentation violation here! end
To Reproduce
Compile the sv.ecf system and run it in workbench mode.