yard-contracts 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/yard-contracts/contract_handler.rb +2 -2
- data/lib/yard-contracts/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 42d360186d8be5324d7223a1219342cc04d9f009
|
4
|
+
data.tar.gz: 2a3ab83e5fd4bbf52048899164a5732bee6df672
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 837f4e04d5a62c09a2c141075c48178d6b403927a2b2c64495e07727b73191c39114f0dae0680aef5ab7a717e979845548385bfb27a465a0076bb0a746a08cb1
|
7
|
+
data.tar.gz: 30d876886715397087eee3f8f3abbfb76517ffeebead072d6c58e50f5158f3151eff22d9d1839d1d083b3f6bdac4cc39bb27986a70fa3ac686e8eb7a401ef815
|
@@ -4,7 +4,7 @@
|
|
4
4
|
# https://github.com/lsegal/yard/issues/825
|
5
5
|
require 'yard'
|
6
6
|
|
7
|
-
#require 'contracts/formatters'
|
7
|
+
# require 'contracts/formatters'
|
8
8
|
require 'contracts/builtin_contracts'
|
9
9
|
require 'yard-contracts/formatters'
|
10
10
|
|
@@ -36,7 +36,7 @@ class ContractHandler < YARD::Handlers::Ruby::Base
|
|
36
36
|
|
37
37
|
## Hacky way to test for class methods
|
38
38
|
## TODO: What about module methods? Probably broken.
|
39
|
-
scope = def_method_ast.source.match(/ self\./) ? :class : :instance
|
39
|
+
scope = def_method_ast.source.match(/def +self\./) ? :class : :instance
|
40
40
|
name = def_method_ast.method_name true
|
41
41
|
params = def_method_ast.parameters # YARD::Parser::Ruby::ParameterNode
|
42
42
|
contracts = statement.parameters # YARD::Parser::Ruby::AstNode
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yard-contracts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon George
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-04-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: yard
|