Skip to content

Commit b24d4c1

Browse files
TIHanbaronfel
authored andcommitted
Specializing Operators.op_UnaryPlus for witness info (#9769)
* Initial work to fix op_UnaryPlus witness info * Added UnaryPlusDynamic * update surface area * Only enable type provider test on net472 * Removing UnaryPlusDynamic * fixing build * fix comment * Update prim-types.fs
1 parent 35aaad9 commit b24d4c1

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/fsharp/TcGlobals.fs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1601,6 +1601,11 @@ type public TcGlobals(compilingFslib: bool, ilg:ILGlobals, fslibCcu: CcuThunk, d
16011601
Some (g.array_set_info, [ety], argExprs)
16021602
| "get_Item", [sty; _; _], _, [_; _] when isStringTy g sty ->
16031603
Some (g.getstring_info, [], argExprs)
1604+
| "op_UnaryPlus", [aty], _, [_] ->
1605+
// Call Operators.id
1606+
let info = makeOtherIntrinsicValRef (fslib_MFOperators_nleref, "id", None, None, [vara], ([[varaTy]], varaTy))
1607+
let tyargs = [aty]
1608+
Some (info, tyargs, argExprs)
16041609
| _ ->
16051610
None
16061611

0 commit comments

Comments
 (0)