[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: branches/KDE/4.4/kdebindings/ruby/qtruby/src/lib/Qt
From: Richard Dale <Richard_Dale () tipitina ! demon ! co ! uk>
Date: 2010-02-01 17:39:29
Message-ID: 1265045969.008143.27967.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 1083634 by rdale:
* Simplify the code to distiguish between methods overloaded only on const-ness
CCMAIL: kde-bindings@kde.org
M +3 -7 qtruby4.rb
--- branches/KDE/4.4/kdebindings/ruby/qtruby/src/lib/Qt/qtruby4.rb #1083633:1083634
@@ -2698,7 +2698,7 @@
methodIds.each do
|id|
puts "matching => smoke: #{id.smoke} index: #{id.index}" if debug_level >= DebugLevel::High
- current_match = 0
+ current_match = (isConstMethod(id) ? 1 : 0)
(0...args.length).each do
|i|
current_match += checkarg(get_value_type(args[i]), get_arg_type_name(id, i))
@@ -2712,12 +2712,8 @@
# If ambiguous matches occur the problem must be fixed be adjusting the relative
# ranking of the arg types involved in checkarg().
elsif current_match == best_match
- if !isConstMethod(id) and isConstMethod(chosen)
- chosen = id
- elsif isConstMethod(id) == isConstMethod(chosen)
- puts "multiple methods matching, this is an error" if debug_level >= DebugLevel::Minimal
- chosen = nil
- end
+ puts "multiple methods matching, this is an error" if debug_level >= DebugLevel::Minimal
+ chosen = nil
end
puts "match => #{id.index} score: #{current_match}" if debug_level >= DebugLevel::High
end
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic