Skip to content

Commit 3431e61

Browse files
committed
Merge branch 'fix-671' of https://github.com/dsyme/visualfsharp into dsyme-fix-671
2 parents dc867b3 + 03d85de commit 3431e61

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

src/fsharp/PostInferenceChecks.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@ and CheckExprInContext (cenv:cenv) (env:env) expr (context:ByrefCallContext) =
528528
CheckMultipleInterfaceInstantiations cenv interfaces m
529529

530530
// Allow base calls to F# methods
531-
| Expr.App((InnerExprPat(Expr.Val(v,vFlags,_) as f)),fty,tyargs,(Expr.Val(baseVal,_,_)::rest),m)
531+
| Expr.App((InnerExprPat(ExprValWithPossibleTypeInst(v,vFlags,_,_) as f)),fty,tyargs,(Expr.Val(baseVal,_,_)::rest),m)
532532
when ((match vFlags with VSlotDirectCall -> true | _ -> false) &&
533533
baseVal.BaseOrThisInfo = BaseVal) ->
534534
// dprintfn "GOT BASE VAL USE"

src/fsharp/TastOps.fsi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ val ensureCcuHasModuleOrNamespaceAtPath : CcuThunk -> Ident list -> CompilationP
6161
val stripExpr : Expr -> Expr
6262

6363
val valsOfBinds : Bindings -> FlatVals
64+
val (|ExprValWithPossibleTypeInst|_|) : Expr -> (ValRef * ValUseFlag * TType list * range) option
6465

6566
//-------------------------------------------------------------------------
6667
// Build decision trees imperatively
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
11
// https://github.com/Microsoft/visualfsharp/issues/583
22

33
let rec recValNeverUsedAtRuntime = recFuncIgnoresFirstArg (fun _ -> recValNeverUsedAtRuntime) 1
4-
and recFuncIgnoresFirstArg g v = v
4+
and recFuncIgnoresFirstArg g v = v
5+
6+
// https://github.com/Microsoft/visualfsharp/issues/671
7+
type Base() =
8+
abstract member Method : 't -> unit
9+
default this.Method(t) = ()
10+
11+
and Derived() =
12+
inherit Base()
13+
override this.Method(t) = base.Method(t)

0 commit comments

Comments
 (0)