Sha256: a646ec5b7d3f0749ea58c21854010a2e5e0b1e9b553775ce093bb6fbe35c0629

Contents?: true

Size: 796 Bytes

Versions: 33

Compression:

Stored size: 796 Bytes

Contents

(examples-for type-of
  ("returns pair for a cons cell"
   (type-of (cons "a" "b"))
   pair)

  ("returns 'fn for builtin function"
   (type-of car)
   fn)

  ("returns 'fn for nydp-defined function"
   (type-of register-test)
   fn)

  ("returns 'fn for inline function"
   (type-of (fn (x) (p x)))
   fn)

  ("returns 'string"
   (type-of "foobar")
   string)

  ("returns 'hash for new hash"
   (type-of (hash))
   hash)

  ("returns 'hash for hash literal"
   (type-of { a 1 b 2})
   hash)

  ("returns 'number for an integer"
   (type-of 42)
   number)

  ("returns 'number for a float"
   (type-of 4.2)
   number)

  ("returns 'string for an interpolated string"
   (type-of "foobar ~(+ 1 2)")
   string)

  ("t is Truth"
   (type-of t)
   truth)

  ("nil is nil"
   (type-of nil)
   nil))

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
nydp-0.6.0 lib/lisp/tests/type-of-examples.nydp
nydp-0.5.1 lib/lisp/tests/type-of-examples.nydp
nydp-0.5.0 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.6 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.5 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.3 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.2 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.1 lib/lisp/tests/type-of-examples.nydp
nydp-0.4.0 lib/lisp/tests/type-of-examples.nydp
nydp-0.3.0 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.6 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.5 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.3 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.2 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.1 lib/lisp/tests/type-of-examples.nydp
nydp-0.2.0 lib/lisp/tests/type-of-examples.nydp
nydp-0.1.15 lib/lisp/tests/type-of-examples.nydp
nydp-0.1.14 lib/lisp/tests/type-of-examples.nydp
nydp-0.1.13.2 lib/lisp/tests/type-of-examples.nydp
nydp-0.1.13.1 lib/lisp/tests/type-of-examples.nydp