D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 7231 - Segfault using opDispatch with property notation
Summary: Segfault using opDispatch with property notation
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: Other All
: P2 normal
Assignee: No Owner
URL:
Keywords: ice-on-valid-code
Depends on:
Blocks:
 
Reported: 2012-01-05 05:52 UTC by Robert Clipsham
Modified: 2012-01-26 02:13 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Robert Clipsham 2012-01-05 05:52:06 UTC
The following testcase segfaults with dmd 2.057:
----
struct Contract {
    @property void opDispatch(string name, T)(T value) {
    }
}
void validate() {
    Contract title;
    title.maxLength(255); // Works
    title.maxLength = 255; // Segfault
}
----
When compiled with dmd -c test.d, tested on OS X 64 and Ubuntu 32.
Comment 1 github-bugzilla 2012-01-26 02:11:26 UTC
Commit pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/f88878558c3066abed4f288c9dfa717427041be1
fix Issue 7231 - Segfault using opDispatch with property notation
Comment 2 github-bugzilla 2012-01-26 02:11:38 UTC
Commit pushed to dmd-1.x at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/4f0980fc1fef275d3dbb6994eefeea42e6e863f2
fix Issue 7231 - Segfault using opDispatch with property notation