Show
Ignore:
Timestamp:
03/25/08 18:16:02 (8 months ago)
Author:
Mike Wey
Message:

Support for dmd 2.012

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/demos/gtk/SpawnTests.d

    r358 r480  
    3737    import tango.text.Util; 
    3838    import tango.io.Stdout; 
    39     void writefln( char[] frm, ... ){ 
    40         char[] frm2 = substitute( frm, "%s", "{}" ); 
     39    void writefln( string frm, ... ){ 
     40        string frm2 = substitute( frm, "%s", "{}" ); 
    4141        Stdout( Stdout.layout.convert( _arguments, _argptr, frm2 )).newline; 
    4242    } 
     
    8484    { 
    8585        version(Tango){ 
    86           char[][] args = split( viewInput.getBuffer().getText(), " " ); 
     86          string[] args = split( viewInput.getBuffer().getText(), " " ); 
    8787        } 
    8888        else{ 
    89           char[][] args = std.string.split(viewInput.getBuffer().getText()); 
     89          string[] args = std.string.split(viewInput.getBuffer().getText()); 
    9090        } 
    9191        exec(args); 
    9292    } 
    9393 
    94     private bool exec(char[][] args) 
    95     { 
    96         foreach ( int i, char[] arg ; args) 
     94    private bool exec(string[] args) 
     95    { 
     96        foreach ( int i, string arg ; args) 
    9797        { 
    9898            writefln("[%s] >%s<", i, arg); 
     
    171171    } 
    172172 
    173         public bool syncOutput(char[] line) 
     173        public bool syncOutput(string line) 
    174174        { 
    175175            TextIter iter = new TextIter(); 
     
    179179        } 
    180180 
    181         public bool syncError(char[] line) 
     181        public bool syncError(string line) 
    182182        { 
    183183            TextIter iter = new TextIter(); 
     
    187187        } 
    188188 
    189     public void setInput(char[][] args) 
     189    public void setInput(string[] args) 
    190190    { 
    191191        TextBuffer inBuffer = viewInput.getBuffer(); 
    192         char[] t; 
    193         foreach ( int count, char[] arg; args) 
     192        string t; 
     193        foreach ( int count, string arg; args) 
    194194        { 
    195195            if ( count > 0 ) t ~= " "; 
     
    199199    } 
    200200 
    201     public void setInput(char[] arg) 
     201    public void setInput(string arg) 
    202202    { 
    203203        viewInput.getBuffer().setText(arg); 
     
    207207} 
    208208 
    209 void main(char[][] args) 
     209void main(string[] args) 
    210210{ 
    211211    GtkD.init(args);