* [sup-talk] [PATCH] Small bugfix in keymap run_hook
@ 2010-03-02 18:49 Ben Walton
2010-03-02 18:49 ` [sup-talk] [PATCH] Small bug ifx in keymap run_hook method Ben Walton
2010-03-02 18:58 ` [sup-talk] [PATCH] Small bug fix " Ben Walton
0 siblings, 2 replies; 3+ messages in thread
From: Ben Walton @ 2010-03-02 18:49 UTC (permalink / raw)
To: sup-talk; +Cc: Ben Walton
I just merged the tip of origin/next and sup blew up on me. The
attached patch corrects this bug and, I think, provides the intended
behaviour.
Ben Walton (1):
Small bug ifx in keymap run_hook method
lib/sup/keymap.rb | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk
^ permalink raw reply [flat|nested] 3+ messages in thread
* [sup-talk] [PATCH] Small bug ifx in keymap run_hook method
2010-03-02 18:49 [sup-talk] [PATCH] Small bugfix in keymap run_hook Ben Walton
@ 2010-03-02 18:49 ` Ben Walton
2010-03-02 18:58 ` [sup-talk] [PATCH] Small bug fix " Ben Walton
1 sibling, 0 replies; 3+ messages in thread
From: Ben Walton @ 2010-03-02 18:49 UTC (permalink / raw)
To: sup-talk; +Cc: Ben Walton
Splat the array that is returned from Modes.keymaps.map when it is
passed into Hash[] to avoid an error about an odd number of parameters
being passes to the method.
Error was:
./sup/keymap.rb:129:in `[]': odd number of arguments for Hash
(ArgumentError)
from ./sup/keymap.rb:129:in `run_hook'
from ../bin/sup:98
Signed-off-by: Ben Walton <bwalton@artsci.utoronto.ca>
---
lib/sup/keymap.rb | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/lib/sup/keymap.rb b/lib/sup/keymap.rb
index 93060b8..8d54924 100644
--- a/lib/sup/keymap.rb
+++ b/lib/sup/keymap.rb
@@ -126,7 +126,7 @@ EOS
end
def self.run_hook global_keymap
- modes = Hash[Mode.keymaps.map { |klass,keymap| [Mode.make_name(klass.name),klass] }]
+ modes = Hash[*Mode.keymaps.map { |klass,keymap| [Mode.make_name(klass.name),klass] }]
locals = {
:modes => modes,
:global_keymap => global_keymap,
--
1.7.0
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk
^ permalink raw reply [flat|nested] 3+ messages in thread
* [sup-talk] [PATCH] Small bug fix in keymap run_hook method
2010-03-02 18:49 [sup-talk] [PATCH] Small bugfix in keymap run_hook Ben Walton
2010-03-02 18:49 ` [sup-talk] [PATCH] Small bug ifx in keymap run_hook method Ben Walton
@ 2010-03-02 18:58 ` Ben Walton
1 sibling, 0 replies; 3+ messages in thread
From: Ben Walton @ 2010-03-02 18:58 UTC (permalink / raw)
To: sup-talk; +Cc: Ben Walton
Splat the array that is returned from Modes.keymaps.map when it is
passed into Hash[] to avoid an error about an odd number of parameters
being passes to the method.
Error was:
./sup/keymap.rb:129:in `[]': odd number of arguments for Hash
(ArgumentError)
from ./sup/keymap.rb:129:in `run_hook'
from ../bin/sup:98
Signed-off-by: Ben Walton <bwalton@artsci.utoronto.ca>
---
This time with correct spelling in commit message. :)
lib/sup/keymap.rb | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/lib/sup/keymap.rb b/lib/sup/keymap.rb
index 93060b8..8d54924 100644
--- a/lib/sup/keymap.rb
+++ b/lib/sup/keymap.rb
@@ -126,7 +126,7 @@ EOS
end
def self.run_hook global_keymap
- modes = Hash[Mode.keymaps.map { |klass,keymap| [Mode.make_name(klass.name),klass] }]
+ modes = Hash[*Mode.keymaps.map { |klass,keymap| [Mode.make_name(klass.name),klass] }]
locals = {
:modes => modes,
:global_keymap => global_keymap,
--
1.7.0
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-03-02 19:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-02 18:49 [sup-talk] [PATCH] Small bugfix in keymap run_hook Ben Walton
2010-03-02 18:49 ` [sup-talk] [PATCH] Small bug ifx in keymap run_hook method Ben Walton
2010-03-02 18:58 ` [sup-talk] [PATCH] Small bug fix " Ben Walton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox