Thread overview
No output from Stdout
Mar 17, 2008
Barry Denton
Mar 17, 2008
Lars Ivar Igesund
Mar 17, 2008
Sclytrack
March 17, 2008
I have compiled this but when run it gives no output
why?

module test;
import tango.io.Stdout;
import tango.text.locale.Locale;

 void main(){
 Locale locale = new Locale;
 Stdout("I have lost {} of my birds",20).newline;
 Stdout.formatln("I have {:C} birds on the roof",100);
}
Taking Locale out does not seem to affect it , still no output
I am looking loco
March 17, 2008
Barry Denton wrote:

> I have compiled this but when run it gives no output
> why?
> 
> module test;
> import tango.io.Stdout;
> import tango.text.locale.Locale;
> 
>  void main(){
>  Locale locale = new Locale;
>  Stdout("I have lost {} of my birds",20).newline;
>  Stdout.formatln("I have {:C} birds on the roof",100);
> }
> Taking Locale out does not seem to affect it , still no output
> I am looking loco

Works here (apart from your example probably not doing what you think it
should do.)

-- 
Lars Ivar Igesund
blog at http://larsivi.net
DSource, #d.tango & #D: larsivi
Dancing the Tango
March 17, 2008
void main(){
 Locale locale = new Locale;
 Stdout("I have lost {} of my birds",20).newline;
 Stdout.formatln("I have {:C} birds on the roof",100);
}


I have the following output on your application.

I have lost {} of my birds, 20
I have {unknown format 'C'} birds on the roof

Well if I change the code too.

int main() {
 Locale locale = new Locale;
 Stdout.formatln("I have lost {} of my birds",20);
 Stdout.formatln("I have {} birds on the roof",100);
 Stdout.flush;
 return 0;
}

I get

I have lost 20 of my birds
I have 100 birds on the roof

http://dsource.org/projects/tango/docs/current/tango.io.Stdout.html


Everything I wrote here probably won't help since it gave you no output and I'm just being an idiot again.