aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorSam Anthony <sam@samanthony.xyz>2024-01-20 17:56:39 -0500
committerSam Anthony <sam@samanthony.xyz>2024-01-20 17:56:39 -0500
commit3aaae870ba76d8f0907b10a61d829ad353936306 (patch)
tree8be8cb950d0aa8039cd977c72e2f9438cae4a1e8 /util
parentdb183cf7570e0f4e448ab5ced0ae41969261a815 (diff)
downloadvolute-3aaae870ba76d8f0907b10a61d829ad353936306.zip
flatten source directory structure by removing modules
Diffstat (limited to 'util')
-rw-r--r--util/util.go31
1 files changed, 0 insertions, 31 deletions
diff --git a/util/util.go b/util/util.go
deleted file mode 100644
index b0eae51..0000000
--- a/util/util.go
+++ /dev/null
@@ -1,31 +0,0 @@
-package util
-
-import (
- "fmt"
- "os"
-
- "volute/mass"
- "volute/pressure"
- "volute/temperature"
-)
-
-func Check(err error) {
- if err != nil {
- fmt.Println(err)
- os.Exit(1)
- }
-}
-
-func Insert[T int32 | float32 | temperature.Temperature | pressure.Pressure | mass.FlowRate](slice []T, elem T, i int) []T {
- return append(
- slice[:i],
- append(
- []T{elem},
- slice[i:]...,
- )...,
- )
-}
-
-func Remove[T int32 | float32 | temperature.Temperature | pressure.Pressure | mass.FlowRate](slice []T, i int) []T {
- return append(slice[:i], slice[i+1:]...)
-}