xprint 0.5.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/version.rb +1 -1
- data/lib/xprint.rb +2 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 990179163a84db36aa76ba3ba878bb21641efbb5720823cc635d37b61a95721b
|
4
|
+
data.tar.gz: 513f72918e49b0ff51aecf7181ab4b2a2e288d01d791a6c67b951abbe40fdcdc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c8087e594b361566fe9375e6c77296474a40b5454d24bf7b5e139640f2c033e71d2b9555fadcdac9e1843d5436aaa14b0b928247bd0ffba343994a8a4ff2f903
|
7
|
+
data.tar.gz: d4435f361143d2d9c5660f634256b6eb7444261b40bfd00337699bd6a9370b3f4c93d9581167083dfab0ddd99b62d93866c5461b3ef66830fad358cd8819c56f
|
data/lib/version.rb
CHANGED
data/lib/xprint.rb
CHANGED
@@ -37,10 +37,11 @@ module XPrint
|
|
37
37
|
# X is a Proc, print more compact version of standard Proc.inspect
|
38
38
|
# text.
|
39
39
|
elsif x.class == Proc
|
40
|
+
type = x.lambda? ? 'Lambda' : 'Proc'
|
40
41
|
source, line = x.source_location
|
41
42
|
source = source.gsub('\\', '/').split('/')[-2..-1].join('/')
|
42
43
|
|
43
|
-
return "
|
44
|
+
return "<#{type} @ #{source} [Line #{line}]>"
|
44
45
|
# X is an Array, print list of all items.
|
45
46
|
elsif x.class == Array
|
46
47
|
result = "[\n"
|