steep 0.9.0 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -1
- data/lib/steep/ast/types/proc.rb +1 -1
- data/lib/steep/cli.rb +25 -4
- data/lib/steep/drivers/annotations.rb +14 -3
- data/lib/steep/drivers/check.rb +71 -75
- data/lib/steep/drivers/print_interface.rb +56 -25
- data/lib/steep/drivers/scaffold.rb +7 -4
- data/lib/steep/drivers/utils/each_signature.rb +6 -41
- data/lib/steep/drivers/validate.rb +35 -10
- data/lib/steep/drivers/watch.rb +188 -0
- data/lib/steep/errors.rb +2 -2
- data/lib/steep/project/file.rb +119 -0
- data/lib/steep/project/listener.rb +53 -0
- data/lib/steep/project/options.rb +13 -0
- data/lib/steep/project.rb +231 -0
- data/lib/steep/type_construction.rb +56 -29
- data/lib/steep/version.rb +1 -1
- data/lib/steep.rb +7 -1
- data/sig/project.rbi +106 -0
- data/smoke/hash/f.rb +11 -0
- data/stdlib/builtin.rbi +3 -0
- data/steep.gemspec +3 -1
- metadata +39 -7
- data/lib/steep/drivers/utils/validator.rb +0 -110
- data/sig/signature.rbi +0 -146
- data/sig/types.rbi +0 -43
data/sig/signature.rbi
DELETED
@@ -1,146 +0,0 @@
|
|
1
|
-
class Steep__Signature__Error
|
2
|
-
def initialize: (signature: Steep__Signature) -> any
|
3
|
-
def signature: -> Steep__Signature
|
4
|
-
def puts: (any) -> any
|
5
|
-
end
|
6
|
-
|
7
|
-
class Steep__Signature__Errors__UnknownTypeName <: Steep__Signature__Error
|
8
|
-
def initialize: (signature: Steep__Signature, type: Steep__Type) -> any
|
9
|
-
def type: -> Steep__Type
|
10
|
-
end
|
11
|
-
|
12
|
-
class Steep__BlockType
|
13
|
-
def params: -> Steep__MethodParams
|
14
|
-
def return_type: -> Steep__Type
|
15
|
-
end
|
16
|
-
|
17
|
-
class Steep__MethodParams
|
18
|
-
def each_type: { (Steep__Type) -> any } -> instance
|
19
|
-
end
|
20
|
-
|
21
|
-
class Steep__MethodType
|
22
|
-
def substitute: (klass: Steep__Type, instance: Steep__Type, params: Hash<Symbol, Steep__Type>) -> Steep__MethodType
|
23
|
-
def updated: (?type_params: Array<Symbol>, ?params: Steep__MethodParams, ?block: any, ?return_type: Steep__Type) -> Steep__MethodType
|
24
|
-
def params: -> Steep__MethodParams
|
25
|
-
def return_type: -> Steep__Type
|
26
|
-
def block: -> Steep__BlockType
|
27
|
-
end
|
28
|
-
|
29
|
-
class Steep__Interface
|
30
|
-
def initialize: (name: Symbol, methods: Hash<Symbol, Steep__Method>) -> any
|
31
|
-
end
|
32
|
-
|
33
|
-
class Steep__Method
|
34
|
-
def initialize: (types: Array<Steep__MethodType>, super_method: Steep__Method) -> any
|
35
|
-
def substitute: (klass: Steep__Type, instance: Steep__Type, params: Hash<Symbol, Steep__Type>) -> Steep__Method
|
36
|
-
def types: -> Array<Steep__MethodType>
|
37
|
-
end
|
38
|
-
|
39
|
-
class Steep__Signature
|
40
|
-
end
|
41
|
-
|
42
|
-
class Steep__Signature__Member
|
43
|
-
end
|
44
|
-
|
45
|
-
class Steep__Signature__Errors__IncompatibleOverride <: Steep__Signature__Error
|
46
|
-
def initialize: (signature: Steep__Signature, method_name: Symbol, this_method: Steep__Method, super_method: Steep__Method) -> any
|
47
|
-
def method_name: -> Symbol
|
48
|
-
def this_method: -> Steep__Method
|
49
|
-
def super_method: -> Steep__Method
|
50
|
-
end
|
51
|
-
|
52
|
-
class Steep__SignatureMember__Method <: Steep__Signature__Member
|
53
|
-
def initialize: (name: Symbol, types: Array<Steep__MethodType>) -> any
|
54
|
-
def name: -> Symbol
|
55
|
-
def types: -> Array<Steep__MethodType>
|
56
|
-
end
|
57
|
-
|
58
|
-
class Steep__SignatureMember__Include <: Steep__Signature__Member
|
59
|
-
def initialize: (name: Symbol) -> any
|
60
|
-
def name: -> Symbol
|
61
|
-
end
|
62
|
-
|
63
|
-
class Steep__SignatureMember__Extend <: Steep__Signature__Member
|
64
|
-
def initialize: (name: Symbol) -> any
|
65
|
-
def name: -> Symbol
|
66
|
-
end
|
67
|
-
|
68
|
-
interface _Steep__SignatureMember__Mixin
|
69
|
-
def name: -> Steep__Type
|
70
|
-
end
|
71
|
-
|
72
|
-
interface _Steep__WithMethods
|
73
|
-
def instance_methods: (assignability: any, klass: Steep__Type, instance: Steep__Type, params: Array<Steep__Type>) -> Hash<Symbol, Steep__Method>
|
74
|
-
def module_methods: (assignability: any, klass: Steep__Type, instance: Steep__Type, params: Array<Steep__Type>) -> Hash<Symbol, Steep__Method>
|
75
|
-
def type_application_hash: (Array<Steep__Type>) -> Hash<Symbol, Steep__Type>
|
76
|
-
def members: -> Array<Steep__Signature__Member>
|
77
|
-
def is_class?: -> _Boolean
|
78
|
-
end
|
79
|
-
|
80
|
-
module Steep__Signature__WithMethods : _Steep__WithMethods
|
81
|
-
def instance_methods: (assignability: any, klass: Steep__Type, instance: Steep__Type, params: Array<Steep__Type>) -> Hash<Symbol, Steep__Method>
|
82
|
-
def module_methods: (assignability: any, klass: Steep__Type, instance: Steep__Type, params: Array<Steep__Type>) -> Hash<Symbol, Steep__Method>
|
83
|
-
def merge_methods: (Hash<Symbol, Steep__Method>, Hash<Symbol, Steep__Method>) -> Hash<Symbol, Steep__Method>
|
84
|
-
end
|
85
|
-
|
86
|
-
interface _Steep__WithMembers
|
87
|
-
def members: -> Array<Steep__Signature__Member>
|
88
|
-
def params: -> Array<Symbol>
|
89
|
-
end
|
90
|
-
|
91
|
-
module Steep__Signature__WithMembers : _Steep__WithMembers
|
92
|
-
def each_type: { (Steep__Type) -> any } -> any
|
93
|
-
def validate_mixins: (any, Steep__Interface) -> any
|
94
|
-
end
|
95
|
-
|
96
|
-
interface _Steep__WithParams
|
97
|
-
end
|
98
|
-
|
99
|
-
module Steep__Signature__WithParams : _Steep__WithParams
|
100
|
-
def type_application_hash: (Array<Steep__Type>) -> Hash<Symbol, Steep__Type>
|
101
|
-
end
|
102
|
-
|
103
|
-
class Steep__Signature__Module
|
104
|
-
include Steep__Signature__WithMethods
|
105
|
-
include Steep__Signature__WithMembers
|
106
|
-
include Steep__Signature__WithParams
|
107
|
-
|
108
|
-
def initialize: (name: Symbol, params: Array<Symbol>, members: Array<Steep__Signature__Member>, self_type: Steep__Type) -> any
|
109
|
-
def name: -> Symbol
|
110
|
-
def params: -> Array<Symbol>
|
111
|
-
def members: -> Array<Steep__Signature__Member>
|
112
|
-
def self_type: -> Steep__Type
|
113
|
-
def is_class?: -> _Boolean
|
114
|
-
end
|
115
|
-
|
116
|
-
class Steep__Signature__Class
|
117
|
-
include Steep__Signature__WithMethods
|
118
|
-
include Steep__Signature__WithMembers
|
119
|
-
include Steep__Signature__WithParams
|
120
|
-
|
121
|
-
def initialize: (name: Symbol, params: Array<Symbol>, members: Array<Steep__Signature__Member>, super_class: Steep__Types__Name) -> any
|
122
|
-
def name: -> Symbol
|
123
|
-
def params: -> Array<Symbol>
|
124
|
-
def members: -> Array<Steep__Signature__Member>
|
125
|
-
def super_class: -> Steep__Types__Name
|
126
|
-
def is_class?: -> _Boolean
|
127
|
-
end
|
128
|
-
|
129
|
-
class Steep__Signature__Extension
|
130
|
-
def initialize: (module_name: Symbol, extension_name: Symbol, members: Array<Steep__Signature__Member>) -> any
|
131
|
-
def module_name: -> Symbol
|
132
|
-
def extension_name: -> Symbol
|
133
|
-
def members: -> Array<Steep__Signature__Member>
|
134
|
-
def name: -> Symbol
|
135
|
-
end
|
136
|
-
|
137
|
-
class Steep__Signature__Interface
|
138
|
-
def initialize: (name: Symbol, params: Array<Symbol>, methods: Hash<Symbol, Array<Steep__MethodType>>) -> any
|
139
|
-
|
140
|
-
def name: -> Symbol
|
141
|
-
def params: -> Array<Symbol>
|
142
|
-
def methods: -> Hash<Symbol, Array<Steep__MethodType>>
|
143
|
-
|
144
|
-
def to_interface: (klass: Steep__Type, instance: Steep__Type, params: Array<Steep__Type>) -> any
|
145
|
-
def validate: (any) -> any
|
146
|
-
end
|
data/sig/types.rbi
DELETED
@@ -1,43 +0,0 @@
|
|
1
|
-
class Steep__TypeName
|
2
|
-
def initialize: (name: Symbol) -> any
|
3
|
-
end
|
4
|
-
|
5
|
-
class Steep__Type
|
6
|
-
def closed?: -> _Boolean
|
7
|
-
def substitute: (klass: Steep__Type, instance: Steep__Type, params: Hash<Symbol, Steep__Type>) -> instance
|
8
|
-
end
|
9
|
-
|
10
|
-
class Steep__Types__Name <: Steep__Type
|
11
|
-
def initialize: (name: Steep__TypeName, params: Array<Steep__Type>) -> any
|
12
|
-
|
13
|
-
def name: -> Steep__TypeName
|
14
|
-
def params: -> Array<Steep__Type>
|
15
|
-
|
16
|
-
def self.interface: (name: Symbol, ?params: Array<Steep__Type>) -> Steep__Types__Name
|
17
|
-
def self.module: (name: Symbol, ?params: Array<Steep__Type>) -> Steep__Types__Name
|
18
|
-
def self.instance: (name: Symbol, ?params: Array<Steep__Type>) -> Steep__Types__Name
|
19
|
-
end
|
20
|
-
|
21
|
-
class Steep__Types__Union <: Steep__Type
|
22
|
-
def initialize: (types: Array<Steep__Type>) -> any
|
23
|
-
def types: -> Array<Steep__Type>
|
24
|
-
end
|
25
|
-
|
26
|
-
class Steep__Types__Merge <: Steep__Type
|
27
|
-
def initialize: (types: Array<Steep__Type>) -> any
|
28
|
-
def types: -> Array<Steep__Type>
|
29
|
-
end
|
30
|
-
|
31
|
-
class Steep__Types__Var <: Steep__Type
|
32
|
-
def initialize: (name: Symbol) -> any
|
33
|
-
def name: -> Symbol
|
34
|
-
end
|
35
|
-
|
36
|
-
class Steep__Types__Instance <: Steep__Type
|
37
|
-
end
|
38
|
-
|
39
|
-
class Steep__Types__Class <: Steep__Type
|
40
|
-
end
|
41
|
-
|
42
|
-
class Steep__Types__Any <: Steep__Type
|
43
|
-
end
|