aboutsummaryrefslogtreecommitdiff
path: root/object
diff options
context:
space:
mode:
Diffstat (limited to 'object')
-rw-r--r--object/object.go3
-rw-r--r--object/objecttype_string.go18
2 files changed, 19 insertions, 2 deletions
diff --git a/object/object.go b/object/object.go
index 2754bfb..f77b871 100644
--- a/object/object.go
+++ b/object/object.go
@@ -170,8 +170,7 @@ func (h *Hash) Inspect() string {
var pairs []string
for _, pair := range h.Pairs {
- pairs = append(pairs, fmt.Sprintf("%s: %s",
- pair.Key.Inspect(), pair.Value.Inspect()))
+ pairs = append(pairs, fmt.Sprintf("%s: %s", pair.Key.Inspect(), pair.Value.Inspect()))
}
out.WriteString("{")
diff --git a/object/objecttype_string.go b/object/objecttype_string.go
index 80d3ee6..39336a1 100644
--- a/object/objecttype_string.go
+++ b/object/objecttype_string.go
@@ -4,6 +4,24 @@ package object
import "strconv"
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NULL-0]
+ _ = x[ERROR-1]
+ _ = x[INTEGER-2]
+ _ = x[BOOLEAN-3]
+ _ = x[STRING-4]
+ _ = x[RETURN_VALUE-5]
+ _ = x[FUNCTION-6]
+ _ = x[BUILTIN-7]
+ _ = x[ARRAY-8]
+ _ = x[HASH-9]
+ _ = x[QUOTE-10]
+ _ = x[MACRO-11]
+}
+
const _ObjectType_name = "NULLERRORINTEGERBOOLEANSTRINGRETURN_VALUEFUNCTIONBUILTINARRAYHASHQUOTEMACRO"
var _ObjectType_index = [...]uint8{0, 4, 9, 16, 23, 29, 41, 49, 56, 61, 65, 70, 75}