[plt-scheme] What am I looking at?
MzScheme version 299.26
I am looking at the contents of a variable and I don't understand the notation.
I see things like #7= and #2# which make no sense to me. I do understand
vector and list notation but that's not all I'm seeing as follows:
> x
#7=((#4=#13(object #1=#13(object #0=#13(object #2=#13(object #0# 8 7
"meta-metac
lass" (#3=#13(object #0# 4 3 "meta-behavior" (#1#) (#2# #5=#13(object #0# 6
5 "m
eta-class" (#3#) () () () 0 13 0 ((#4# 3 0)))) () () 0 13 0 ((#4# 3 0)))) () ()
() 0 13 0 ((#4# 3 0))) 1 0 "MetaClass" (#6=#13(object #3# 5 4 "<behavior>"
(#4#)
(#0# #8=#13(object #5# 7 6 "<class>" (#6#) (#1#) () () 0 13 0 ((#4# 3
0)))) ()
() 0 13 0 #7#)) () () () 0 13 0 ((#4# 3 0))) 2 1 "meta-object" (#8#)
(#9=#13(obj
ect #0# 10 9 "meta-generic" (#1#) () () () 0 13 0 ((#4# 3 0)))
#10=#13(object #0
# 9 8 "meta-method" (#1#) () () () 0 13 0 ((#4# 3 0))) #3#) () () 0 13 0
((#4# 3
0))) 3 2 "<object>" () (#13(object #9# 12 11 "<generic>" (#4#) () () () 5
8 0 (
(#4# 3 0))) #13(object #10# 11 10 "<method>" (#4#) () () () 5 8 0 ((#4# 3
0))) #
6#) () () 3 3 0 ()) 3 0))
> (pair? x)
#t
> (length x)
1
> (set! x (car x))
> x
#7=(#4=#13(object #1=#13(object #0=#13(object #2=#13(object #0# 8 7
"meta-metacl
ass" (#3=#13(object #0# 4 3 "meta-behavior" (#1#) (#2# #5=#13(object #0# 6
5 "me
ta-class" (#3#) () () () 0 13 0 ((#4# 3 0)))) () () 0 13 0 ((#4# 3 0)))) ()
() (
) 0 13 0 ((#4# 3 0))) 1 0 "MetaClass" (#6=#13(object #3# 5 4 "<behavior>" (#4#)
(#0# #8=#13(object #5# 7 6 "<class>" (#6#) (#1#) () () 0 13 0 ((#4# 3 0))))
() (
) 0 13 0 (#7#))) () () () 0 13 0 ((#4# 3 0))) 2 1 "meta-object" (#8#)
(#9=#13(ob
ject #0# 10 9 "meta-generic" (#1#) () () () 0 13 0 ((#4# 3 0)))
#10=#13(object #
0# 9 8 "meta-method" (#1#) () () () 0 13 0 ((#4# 3 0))) #3#) () () 0 13 0 ((#4#
3 0))) 3 2 "<object>" () (#13(object #9# 12 11 "<generic>" (#4#) () () () 5 8 0
((#4# 3 0))) #13(object #10# 11 10 "<method>" (#4#) () () () 5 8 0 ((#4# 3 0)))
#6#) () () 3 3 0 ()) 3 0)
> (pair? x)
#t
> (length x)
3
> (set! x (car x))
> x
#4=#13(object #1=#13(object #0=#13(object #2=#13(object #0# 8 7
"meta-metaclass"
(#3=#13(object #0# 4 3 "meta-behavior" (#1#) (#2# #5=#13(object #0# 6 5
"meta-c
lass" (#3#) () () () 0 13 0 ((#4# 3 0)))) () () 0 13 0 ((#4# 3 0)))) () () () 0
13 0 ((#4# 3 0))) 1 0 "MetaClass" (#6=#13(object #3# 5 4 "<behavior>" (#4#)
(#0#
#7=#13(object #5# 7 6 "<class>" (#6#) (#1#) () () 0 13 0 ((#4# 3 0)))) ()
() 0
13 0 ((#4# 3 0)))) () () () 0 13 0 ((#4# 3 0))) 2 1 "meta-object" (#7#)
(#8=#13(
object #0# 10 9 "meta-generic" (#1#) () () () 0 13 0 ((#4# 3 0))) #9=#13(object
#0# 9 8 "meta-method" (#1#) () () () 0 13 0 ((#4# 3 0))) #3#) () () 0 13 0
((#4#
3 0))) 3 2 "<object>" () (#13(object #8# 12 11 "<generic>" (#4#) () () ()
5 8 0
((#4# 3 0))) #13(object #9# 11 10 "<method>" (#4#) () () () 5 8 0 ((#4# 3
0)))
#6#) () () 3 3 0 ())
> (vector? x)
#t
> (vector-length x)
13
> (vector-ref x 0)
object
> (vector-ref x 1)
#1=#13(object #0=#13(object #2=#13(object #0# 8 7 "meta-metaclass"
(#3=#13(objec
t #0# 4 3 "meta-behavior" (#1#) (#2# #5=#13(object #0# 6 5 "meta-class"
(#3#) ()
() () 0 13 0 ((#4=#13(object #1# 3 2 "<object>" () (#13(object
#8=#13(object #0
# 10 9 "meta-generic" (#1#) () () () 0 13 0 ((#4# 3 0))) 12 11 "<generic>"
(#4#)
() () () 5 8 0 ((#4# 3 0))) #13(object #9=#13(object #0# 9 8
"meta-method" (#1#
) () () () 0 13 0 ((#4# 3 0))) 11 10 "<method>" (#4#) () () () 5 8 0 ((#4#
3 0))
) #6=#13(object #3# 5 4 "<behavior>" (#4#) (#0# #7=#13(object #5# 7 6 "<class>"
(#6#) (#1#) () () 0 13 0 ((#4# 3 0)))) () () 0 13 0 ((#4# 3 0)))) () () 3 3
0 ()
) 3 0)))) () () 0 13 0 ((#4# 3 0)))) () () () 0 13 0 ((#4# 3 0))) 1 0
"MetaClass
" (#6#) () () () 0 13 0 ((#4# 3 0))) 2 1 "meta-object" (#7#) (#8# #9# #3#)
() ()
0 13 0 ((#4# 3 0)))
> (vector-ref x 2)
3
> (vector-ref x 3)
2
> (vector-ref x 4)
"<object>"
> (vector-ref x 5)
()
> (vector-ref x 6)
#3=(#13(object #6=#13(object #0=#13(object #7=#13(object #0# 8 7
"meta-metaclass
" (#1=#13(object #0# 4 3 "meta-behavior" (#2=#13(object #0# 2 1
"meta-object" (#
5=#13(object #8=#13(object #0# 6 5 "meta-class" (#1#) () () () 0 13 0
((#4=#13(o
bject #2# 3 2 "<object>" () #3# () () 3 3 0 ()) 3 0))) 7 6 "<class>"
(#9=#13(obj
ect #1# 5 4 "<behavior>" (#4#) (#0# #5#) () () 0 13 0 ((#4# 3 0)))) (#2#) () ()
0 13 0 ((#4# 3 0)))) (#6# #10=#13(object #0# 9 8 "meta-method" (#2#) () () () 0
13 0 ((#4# 3 0))) #1#) () () 0 13 0 ((#4# 3 0)))) (#7# #8#) () () 0 13 0
((#4# 3
0)))) () () () 0 13 0 ((#4# 3 0))) 1 0 "MetaClass" (#9#) () () () 0 13 0
((#4#
3 0))) 10 9 "meta-generic" (#2#) () () () 0 13 0 ((#4# 3 0))) 12 11 "<generic>"
(#4#) () () () 5 8 0 ((#4# 3 0))) #13(object #10# 11 10 "<method>" (#4#) ()
() (
) 5 8 0 ((#4# 3 0))) #9#)
-------
Download source code to my Dynace Object Oriented
Extension to C from: http://algorithms.us
Blake McBride (blake at algorithms.us)
Algorithms Corporation