mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-10-17 08:17:26 +02:00
[svn r38] * resizing dynamic arrays support
* throw is replaced with assert(0) * catch is ignored * better foreach support * various bugfixes
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
module throw1;
|
||||
|
||||
extern(C) int rand();
|
||||
|
||||
class C
|
||||
{
|
||||
}
|
||||
|
||||
void func()
|
||||
{
|
||||
if (rand() & 1)
|
||||
throw new C;
|
||||
}
|
||||
|
||||
int main()
|
||||
{
|
||||
try
|
||||
{
|
||||
func();
|
||||
}
|
||||
catch(Object)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user