On Tue, Nov 11, 2008 at 3:02 PM, Bruce Johnson <[EMAIL PROTECTED]> wrote:

> How about we start a convention for -Xunsafe:yyy flags, like
>
> -Xunsafe:disableArrayIndexChecks
> -Xunsafe:disableClassCastChecks
> -Xunsafe:disableDefensiveCollections
>
>
> then we'd want a roll-up flag like
>
> -Xunsafe:all
>
>
> Of course, we'd want to not document these.
>
> @Ray: The compiler guys are slammed right now. But if you have anything
> resembling a patch that could start this pattern, I think that's the only
> realistic way to get this done in the short term. Also, I'd like to see if
> Scott/Lex/anyone else disagree before we proceeded down this path.
>

Something related we talked about was a flag indicating the compiler was
free to generate code that would be broken if you get certain compiler
warnings.  For example, the compiler has to insert casts even when you have
List<String> because it is possible other dealing with a raw List put
something besides a String in it.  Such a use would generate a warning, so
if you didn't suppress the warning and you didn't get one, it would be ok
for the compiler to remove some extra code.  Probably better to make it a
failure, so something like -assumeGenericCorrectness or something, and what
would previously be a warning regarding generics before would now be an
error but you would produce better code.

-- 
John A. Tamplin
Software Engineer (GWT), Google

--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/Google-Web-Toolkit-Contributors
-~----------~----~----~----~------~----~------~--~---

Reply via email to