keyword_arguments 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/ChangeLog +4 -0
  2. data/Rakefile +1 -1
  3. data/lib/keyword_arguments.rb +3 -3
  4. metadata +21 -10
data/ChangeLog CHANGED
@@ -1,3 +1,7 @@
1
+ 2010-04-05 Dominik Honnef <dominikho@gmx.net>
2
+
3
+ * lib/keyword_arguments.rb (Module#define_our_temporary_method_added): added support for blocks
4
+
1
5
  2009-10-31 Dominik Honnef <dominikho@gmx.net>
2
6
 
3
7
  * test/*: replaced test/unit with baretest
data/Rakefile CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'rubygems'
2
2
  require 'rake/gempackagetask'
3
3
 
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.1"
5
5
 
6
6
  spec = Gem::Specification.new do |s|
7
7
  s.name = "keyword_arguments"
@@ -53,7 +53,7 @@ class Module
53
53
  which_define_method = :define_singleton_method
54
54
  end
55
55
 
56
- self.send(which_define_method, name) do |*args|
56
+ self.send(which_define_method, name) do |*args, &block|
57
57
  args = args[0] || Hash.new
58
58
 
59
59
  # check for unallowed keys
@@ -75,9 +75,9 @@ class Module
75
75
  # call the real method
76
76
  case hook
77
77
  when :method_added
78
- our_method.bind(self).call(args)
78
+ our_method.bind(self).call(args, &block)
79
79
  when :singleton_method_added
80
- our_method.call(args)
80
+ our_method.call(args, &block)
81
81
  end
82
82
  rescue => e
83
83
  # hiding ourself from the backtrace
metadata CHANGED
@@ -1,7 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: keyword_arguments
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 1
8
+ - 1
9
+ version: 0.1.1
5
10
  platform: ruby
6
11
  authors:
7
12
  - Dominik Honnef
@@ -9,19 +14,21 @@ autorequire:
9
14
  bindir: bin
10
15
  cert_chain: []
11
16
 
12
- date: 2009-11-01 00:00:00 +01:00
17
+ date: 2010-04-11 00:00:00 +02:00
13
18
  default_executable:
14
19
  dependencies:
15
20
  - !ruby/object:Gem::Dependency
16
21
  name: baretest
17
- type: :development
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
20
24
  requirements:
21
25
  - - ">="
22
26
  - !ruby/object:Gem::Version
27
+ segments:
28
+ - 0
23
29
  version: "0"
24
- version:
30
+ type: :development
31
+ version_requirements: *id001
25
32
  description: keyword_arguments comes with a bunch of convenient methods for making "named arguments" (hashes as method arguments) in Ruby less painfull
26
33
  email: dominikho@gmx.net
27
34
  executables: []
@@ -36,7 +43,7 @@ files:
36
43
  - ChangeLog
37
44
  - README.markdown
38
45
  - LICENSE
39
- has_rdoc: yard
46
+ has_rdoc: true
40
47
  homepage: http://keywordargs.rubyforge.org/
41
48
  licenses: []
42
49
 
@@ -49,18 +56,22 @@ required_ruby_version: !ruby/object:Gem::Requirement
49
56
  requirements:
50
57
  - - ">="
51
58
  - !ruby/object:Gem::Version
59
+ segments:
60
+ - 1
61
+ - 9
62
+ - 1
52
63
  version: 1.9.1
53
- version:
54
64
  required_rubygems_version: !ruby/object:Gem::Requirement
55
65
  requirements:
56
66
  - - ">="
57
67
  - !ruby/object:Gem::Version
68
+ segments:
69
+ - 0
58
70
  version: "0"
59
- version:
60
71
  requirements: []
61
72
 
62
73
  rubyforge_project: keywordargs
63
- rubygems_version: 1.3.5
74
+ rubygems_version: 1.3.6
64
75
  signing_key:
65
76
  specification_version: 3
66
77
  summary: keyword_arguments comes with a bunch of convenient methods for making "named arguments" (hashes as method arguments) in Ruby less painfull