summaryrefslogtreecommitdiffstats
path: root/lib/byte.go
diff options
context:
space:
mode:
authorsiddharth <s@ricketyspace.net>2021-06-06 15:29:19 -0400
committersiddharth <s@ricketyspace.net>2021-06-06 15:29:19 -0400
commit4af3ded113719f61b7249a33358af01568098c5c (patch)
tree4356179ad89e4e195a258187a70df5425bfeb52c /lib/byte.go
parent3e5b67b5f6e8bc703f4497f37611e1058a5d3c78 (diff)
lib: add `ByteIsUpper`
Diffstat (limited to 'lib/byte.go')
-rw-r--r--lib/byte.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/byte.go b/lib/byte.go
index a29a7b0..68d07bf 100644
--- a/lib/byte.go
+++ b/lib/byte.go
@@ -32,3 +32,10 @@ func BytesInCommon(bbytes [][]byte) []byte {
}
return common
}
+
+func ByteIsUpper(b byte) bool {
+ if 'A' <= b && b <= 'Z' {
+ return true
+ }
+ return false
+}