July 13, 2005
This is with DMD 0.128 on Windows XP SP2.

Shortest test cases:
--
void main() {
	int f = &function() {};
}
--
void main() {
	int f = &delegate() {};
}
--

The former gives me (correctly) the error:
asdf.d(2): __funcliteral1 is not an lvalue

While the latter gives (also correctly):
asdf.d(2): __dgliteral1 is not an lvalue

Up to now, I'd say the behaviour is correct. However, after outputting the error message Windows tells me that "dmd.exe has encountered a problem and needs to close. We are sorry for the inconvenience. (etc)"
--- the compiler crashes completely.
July 18, 2005
Deewiant wrote:

| This is with DMD 0.128 on Windows XP SP2.
|
| Shortest test cases:
| --
| void main() {
| 	int f = &function() {};
| }
| --
| void main() {
| 	int f = &delegate() {};
| }
| --
|
| The former gives me (correctly) the error:
| asdf.d(2): __funcliteral1 is not an lvalue
|
| While the latter gives (also correctly):
| asdf.d(2): __dgliteral1 is not an lvalue
|
| Up to now, I'd say the behaviour is correct. However, after outputting
| the error message Windows tells me that "dmd.exe has encountered a
| problem and needs to close. We are sorry for the inconvenience. (etc)"
| --- the compiler crashes completely.

Added to DStress as
http://dstress.kuehne.cn/nocompile/d/delegate_15.d
http://dstress.kuehne.cn/nocompile/f/function_03.d

Thomas