Juno for D2 (Working status unknown)

Jonathan M Davis jmdavisProg at gmx.com
Sun Nov 6 17:38:05 PST 2011


On Monday, November 07, 2011 00:21:29 Jesse Phillips wrote:
> Disclaimer: Don't expect it to work.
> 
> I've made changes to the Juno Library such that it will compile into
> a .lib with DMD 2.056. However this does not mean it will compile for the
> examples or user code. It also does not mean that it will work once
> compiled.
> 
> https://github.com/he-the-great/Juno-Windows-Class-Library
> 
> The worst changes I made come from this commit:
> 
> https://github.com/he-the-great/Juno-Windows-Class-Library/
> commit/6b7c970ddf06921038d5ad3145cc835abb31dbf6
> 
> I couldn't understand how this compiled in the passed, so I just version
> (none)'d the blocks. What does scope(failure) return; do?
> 
> Anyway I'm hoping to get something working with COM using it, but I
> wouldn't hold my breath that I'd figure out how to get it working if it
> didn't.

Wow, this post must be important. I got it 5 times! ;)

I believe that

scope(failure) return;

becomes

try
{
	//everything in the scope after the scope statement.
}
catch(Exception e)
{
    return;
}

So, it would basically be just ignoring all exceptions. I'm not sure if it's a 
good thing or not that the compiler allows that, since I'd typically argue 
that scope statements shouldn't have any affect on control flow like that. But 
maybe it should be allowed. I don't know. scope statements can result in 
interesting errors when you try and do stuff like put flow control statements in 
them, since they're just lowered to try-catch-finally blocks.

- Jonathan M Davis


More information about the Digitalmars-d-announce mailing list