typespec 0.1.0.6 → 0.1.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ddfcf8dfafb5a8295b92253447cb43a9e83a6623
4
- data.tar.gz: b71676b0515e45c7e0e7ee0a59aa022eea3ab84d
3
+ metadata.gz: 119a78d55a6883427d8a309f492bf5b0b4a0ec27
4
+ data.tar.gz: 2d93ed4b2b71ef92a392788b240737790bae613f
5
5
  SHA512:
6
- metadata.gz: 595f9a3c3199868f4ebbfe55d0e3353b54edd5a5f37aa789fa1a2d456c39c59e8a1dc2fbc2d97a5a3ce32c17f9fe63fade4be69633b9c1337d447d85f07df4bd
7
- data.tar.gz: 06be9dde73d6e75b8a855f590762c4d80d851939e71e4f62ff0ebccc5c15010d4e435680f7b11ba750f674b042709264609d4562df099216e333a9bd50f316a0
6
+ metadata.gz: bd6c90fe94c6dcc5fc45189badfe3aa996032bc29acdf8b54ece851e1467ad1593fac1dc7c01b215415f2b26020d746f28f5d3982de3fe5f82cf858ca37b6154
7
+ data.tar.gz: 65dc8ed51f8dfd2b0288018ee5cdeaede4075ed0cb5b2ba0d52cf4c68f6e73fb4ae0d055540e80c8e01550621ef236266f638481207ebaabdcf84690cce506d8
data/lib/typespec.rb CHANGED
@@ -7,7 +7,10 @@ module Typespec
7
7
  # TODO(mtwilliams): Document this monstrosity.
8
8
 
9
9
  # ...
10
- def self.any; Typespec::Any; end
10
+ def self.nothing; Typespec.nil; end
11
+
12
+ # ...
13
+ def self.anything; Typespec::Any; end
11
14
 
12
15
  # ...
13
16
  class Any
@@ -97,7 +100,7 @@ module Typespec
97
100
  class Hash
98
101
  def initialize(pairs={})
99
102
  @pairs = pairs
100
- @pairs = {Typespec.any => Typespec.any} if @pairs.nil? or @pairs.empty?
103
+ @pairs = {Typespec.anything => Typespec.anything} if @pairs.nil? or @pairs.empty?
101
104
  end
102
105
 
103
106
  def self.[](pairs={})
@@ -124,7 +127,7 @@ module Typespec
124
127
  class Struct
125
128
  def initialize(*properties, **properties_with_spec)
126
129
  if !properties.empty?
127
- @properties = Hash[properties.map{|name| [name, Typespec.any]}]
130
+ @properties = Hash[properties.map{|name| [name, Typespec.anything]}]
128
131
  elsif properties_with_spec
129
132
  @properties = properties_with_spec
130
133
  else
data/lib/typespec/gem.rb CHANGED
@@ -41,7 +41,7 @@ module Typespec
41
41
  end
42
42
 
43
43
  module VERSION #:nodoc:
44
- MAJOR, MINOR, PATCH, PRE = [0, 1, 0, 6]
44
+ MAJOR, MINOR, PATCH, PRE = [0, 1, 0, 7]
45
45
  STRING = [MAJOR, MINOR, PATCH, PRE].compact.join('.')
46
46
  end
47
47
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: typespec
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0.6
4
+ version: 0.1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Williams