extending 'import' using 'with'

Brad Anderson via Digitalmars-d digitalmars-d at puremagic.com
Wed Apr 1 10:28:32 PDT 2015


On Wednesday, 1 April 2015 at 10:21:46 UTC, Mike James wrote:
> Just a thought...
>
> How about adding the keyword 'with' to 'import' to save on 
> typing :-)
>
> import  org.eclipse.swt.widgets.Canvas,
>         org.eclipse.swt.widgets.Composite,
>         org.eclipse.swt.events.DisposeListener,
>         org.eclipse.swt.events.DisposeEvent,
>         org.eclipse.swt.events.PaintListener,
>         org.eclipse.swt.events.PaintEvent;
>
> import with (org.eclipse.swt) {
>         widgets.Canvas,
>         widgets.Composite,
>         events.DisposeListener,
>         events.DisposeEvent,
>         events.PaintListener,
>         events.PaintEvent;
> }
>
>
> Regards,
>
> -=mike=-

Weird timing. I just had this idea a couple nights ago and was 
going to post about it here at some point. So I guess that means 
a +1 from me :).


More information about the Digitalmars-d mailing list