Changeset 17351


Ignore:
Timestamp:
11/15/19 13:17:53 (3 weeks ago)
Author:
chaider
Message:

#3032 Added type information for MethodInfo in SymbolicDataAnalysisExpressionCompiledTreeInterpreter class for the IsAlmost method to fix ambiguous reflection

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/HeuristicLab.Common/3.3/DoubleExtensions.cs

    r17350 r17351  
    2828    /// <param name="x">First double value to be checked</param>
    2929    /// <param name="y">Second double value to compare with</param>
    30     /// <returns></returns>
     30    /// <returns>true if the difference is <= 1.0E-12</returns>
    3131    public static bool IsAlmost(this double x, double y) {
    3232      var epsilon = 1.0E-12;
     
    4040    /// <param name="y">Second double value to compare with</param>
    4141    /// <param name="epsilon">Error term to specify the precision</param>
    42     /// <returns></returns>
     42    /// <returns>true if the difference is <= epsilon</returns>
    4343    public static bool IsAlmost(this double x, double y, double epsilon) {
    4444      if (double.IsInfinity(x)) {
  • trunk/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter/SymbolicDataAnalysisExpressionCompiledTreeInterpreter.cs

    r17180 r17351  
    5252    private static readonly MethodInfo Log = typeof(Math).GetMethod("Log", new[] { typeof(double) });
    5353    private static readonly MethodInfo IsNaN = typeof(double).GetMethod("IsNaN");
    54     private static readonly MethodInfo IsAlmost = typeof(DoubleExtensions).GetMethod("IsAlmost");
     54    private static readonly MethodInfo IsAlmost = typeof(DoubleExtensions).GetMethod("IsAlmost", new Type[] { typeof(double), typeof(double)});
    5555    private static readonly MethodInfo Gamma = typeof(alglib).GetMethod("gammafunction", new[] { typeof(double) });
    5656    private static readonly MethodInfo Psi = typeof(alglib).GetMethod("psi", new[] { typeof(double) });
Note: See TracChangeset for help on using the changeset viewer.