mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-01-12 02:43:14 +01:00
Added test case for bug #100
Removed dubious check for not emitting static private global in other modules without access. This should be handled properly somewhere else, it's causing unresolved global errors for stuff that should work (in MiniD)
This commit is contained in:
@@ -184,7 +184,7 @@ const LLType* DtoType(Type* t)
|
||||
return llvm::OpaqueType::get();
|
||||
|
||||
default:
|
||||
printf("trying to convert unknown type with value %d\n", t->ty);
|
||||
printf("trying to convert unknown type '%s' with value %d\n", t->toChars(), t->ty);
|
||||
assert(0);
|
||||
}
|
||||
return 0;
|
||||
|
||||
@@ -618,11 +618,6 @@ void VarDeclaration::toObjFile(int multiobj)
|
||||
{
|
||||
Logger::println("data segment");
|
||||
|
||||
// we don't want to touch private static members at all !!!
|
||||
// template instances should always be emitted
|
||||
if (!DtoIsTemplateInstance(this) && prot() == PROTprivate && getModule() != gIR->dmodule)
|
||||
return;
|
||||
|
||||
// don't duplicate work
|
||||
if (this->ir.resolved) return;
|
||||
this->ir.resolved = true;
|
||||
|
||||
10
tests/mini/tryfinally1.d
Normal file
10
tests/mini/tryfinally1.d
Normal file
@@ -0,0 +1,10 @@
|
||||
void main()
|
||||
{
|
||||
try
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
debug {} // the debug statement body can be anything
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user