1985-02-04 22:18:16 +00:00
|
|
|
#include "bc_string.h"
|
|
|
|
#include "bc_io.h"
|
1984-11-29 14:22:02 +00:00
|
|
|
|
1994-06-24 11:31:16 +00:00
|
|
|
/* $Id$ */
|
1984-11-29 14:22:02 +00:00
|
|
|
|
|
|
|
/* assume that the channel has been set */
|
|
|
|
|
|
|
|
_wrnl()
|
|
|
|
{
|
|
|
|
if( fputc('\n',_chanwr) == EOF) error(29);
|
|
|
|
}
|
|
|
|
_wrcomma()
|
|
|
|
{
|
|
|
|
if( fputc(',',_chanwr) == EOF) error(29);
|
|
|
|
}
|
|
|
|
_wrint(i)
|
|
|
|
int i;
|
|
|
|
{
|
|
|
|
if(i>0)
|
|
|
|
if( fputc(' ',_chanwr)==EOF) error(29);
|
|
|
|
fprintf(_chanwr,"%d",i);
|
1985-01-21 23:58:07 +00:00
|
|
|
if( ferror(_chanwr) ) error(29);
|
1984-11-29 14:22:02 +00:00
|
|
|
}
|
|
|
|
_wrflt(f)
|
|
|
|
double f;
|
|
|
|
{
|
1985-01-21 23:58:07 +00:00
|
|
|
fprintf(_chanwr,"%f",f);
|
|
|
|
if( ferror(_chanwr) ) error(29);
|
1984-11-29 14:22:02 +00:00
|
|
|
}
|
|
|
|
_wrstr(s)
|
|
|
|
String *s;
|
|
|
|
{
|
1985-01-21 23:58:07 +00:00
|
|
|
fprintf(_chanwr,"\"%s\"",s->strval);
|
|
|
|
if( ferror(_chanwr) ) error(29);
|
1984-11-29 14:22:02 +00:00
|
|
|
}
|