1384 – Compiler segfaults when using struct variable like a function with no opCall member.

D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 1384 - Compiler segfaults when using struct variable like a function with no opCall member.
Summary: Compiler segfaults when using struct variable like a function with no opCall ...
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D1 (retired)
Hardware: x86 Linux
: P2 normal
Assignee: Walter Bright
URL:
Keywords: ice-on-invalid-code
: 1494 (view as issue list)
Depends on:
Blocks:
Reported: 2007年07月28日 13:18 UTC by Aziz Köksal
Modified: 2014年02月16日 15:25 UTC (History)
1 user (show)

See Also:


Attachments
Add an attachment (proposed patch, testcase, etc.)

Note You need to log in before you can comment on or make changes to this issue.
Description Aziz Köksal 2007年07月28日 13:18:23 UTC
If you comment out a or b in the union the compiler doesn't segfault anymore and it shows the following error message: Error: structliteral has no effect in expression (Foo(0))
struct Foo
{
 union
 {
 int a;
 int b;
 }
}
int bla()
{
 Foo next;
 next(); // Error: structliteral has no effect in expression (Foo(0))
}
Comment 1 David Friedman 2007年09月14日 00:31:10 UTC
*** Bug 1494 has been marked as a duplicate of this bug. ***
Comment 2 Walter Bright 2007年09月28日 22:09:28 UTC
Fixed dmd 1.021 and 2.004


AltStyle によって変換されたページ (->オリジナル) /