aboutsummaryrefslogtreecommitdiffstats
path: root/calc.go
diff options
context:
space:
mode:
Diffstat (limited to 'calc.go')
-rw-r--r--calc.go12
1 files changed, 10 insertions, 2 deletions
diff --git a/calc.go b/calc.go
index 8afc43a..1d969cc 100644
--- a/calc.go
+++ b/calc.go
@@ -5,9 +5,17 @@ import (
"strings"
)
+type AngleMode int
+
+const (
+ modeDeg = iota
+ modeRad
+)
+
type Calculator struct {
- stack Stack
- buf string
+ stack Stack
+ buf string
+ anglem AngleMode
}
// swap swaps the values of the buffer and the bottom element of the stack. If