summaryrefslogtreecommitdiff
path: root/graphics/asymptote/runfile.in
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-08-07 03:02:55 +0000
committerNorbert Preining <norbert@preining.info>2020-08-07 03:02:55 +0000
commit3710c23789342d9d88783cbe9ad23eb5263a7c33 (patch)
tree1c40b2bfb9f6b652f7877ad0991f5d6b44391154 /graphics/asymptote/runfile.in
parentd99fea72e367e8d4d2809b43b3b0206b1bb526b8 (diff)
CTAN sync 202008070302
Diffstat (limited to 'graphics/asymptote/runfile.in')
-rw-r--r--graphics/asymptote/runfile.in54
1 files changed, 27 insertions, 27 deletions
diff --git a/graphics/asymptote/runfile.in b/graphics/asymptote/runfile.in
index 39eb464c28..f1554940f3 100644
--- a/graphics/asymptote/runfile.in
+++ b/graphics/asymptote/runfile.in
@@ -13,7 +13,7 @@ file* => primFile()
#include "array.h"
#ifdef __CYGWIN__
-extern "C" int mkstemp(char *c);
+ extern "C" int mkstemp(char *c);
#endif
using namespace camp;
@@ -48,11 +48,11 @@ file* input(string name=emptystring, bool check=true,
f=new ibfile(name,check);
} else if(mode == "xdr") {
#ifdef HAVE_RPC_RPC_H
- f=new ixfile(name,check);
-#else
- ostringstream buf;
- buf << name << ": XDR read support not enabled";
- error(buf);
+ f=new ixfile(name,check);
+#else
+ ostringstream buf;
+ buf << name << ": XDR read support not enabled";
+ error(buf);
#endif
} else if(mode == "") {
char c=comment.empty() ? (char) 0 : comment[0];
@@ -63,7 +63,7 @@ file* input(string name=emptystring, bool check=true,
buf << name << ": invalid file mode '" << mode << "'";
error(buf);
}
-
+
f->open();
return f;
}
@@ -82,7 +82,7 @@ file* output(string name=emptystring, bool update=false,
if(update)
f=new ioxfile(name);
else f=new oxfile(name);
-#else
+#else
ostringstream buf;
buf << name << ": XDR write support not enabled";
error(buf);
@@ -98,10 +98,10 @@ file* output(string name=emptystring, bool update=false,
buf << name << ": invalid file mode '" << mode << "'";
error(buf);
}
-
+
f->open();
if(update) f->seek(0,false);
-
+
return f;
}
@@ -130,13 +130,13 @@ void close(file *f)
f->close();
}
-Int precision(file *f=NULL, Int digits=0)
+Int precision(file *f=NULL, Int digits=0)
{
if(f == 0) f=&camp::Stdout;
return f->precision(digits);
}
-void flush(file *f)
+void flush(file *f)
{
f->flush();
}
@@ -304,21 +304,21 @@ file* :readSetHelper(Int i, file *f)
{
switch(i) {
case 1:
- f->dimension(-2);
- break;
-
+ f->dimension(-2);
+ break;
+
case 2:
- f->dimension(-2,-2);
- break;
-
+ f->dimension(-2,-2);
+ break;
+
case 3:
- f->dimension(-2,-2,-2);
- break;
-
+ f->dimension(-2,-2,-2);
+ break;
+
default:
- f->dimension();
+ f->dimension();
}
-
+
return f;
}
@@ -328,22 +328,22 @@ callable* :readSet(file *f)
}
// Delete file named s.
-Int delete(string s)
+Int delete(string s)
{
s=outpath(s);
Int rc=unlink(s.c_str());
- if(rc == 0 && verbose > 0)
+ if(rc == 0 && verbose > 0)
cout << "Deleted " << s << endl;
return rc;
}
// Rename file "from" to file "to".
-Int rename(string from, string to)
+Int rename(string from, string to)
{
from=outpath(from);
to=outpath(to);
Int rc=rename(from.c_str(),to.c_str());
- if(rc == 0 && verbose > 0)
+ if(rc == 0 && verbose > 0)
cout << "Renamed " << from << " to " << to << endl;
return rc;
}