summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'util.c')
-rw-r--r--util.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/util.c b/util.c
index 0cd4354..e114da5 100644
--- a/util.c
+++ b/util.c
@@ -33,6 +33,26 @@ fmax(double a, double b)
}
void
+swapi(int *a, int *b)
+{
+ int t;
+
+ t = *a;
+ *a = *b;
+ *b = t;
+}
+
+void
+swappt(Point *a, Point *b)
+{
+ Point t;
+
+ t = *a;
+ *a = *b;
+ *b = t;
+}
+
+void
memsetd(double *p, double v, usize len)
{
double *dp;