Skip to content

Commit

Permalink
work around F# bug constructing System.Exception() inside quotation i…
Browse files Browse the repository at this point in the history
…n profile 259: dotnet/fsharp#68
  • Loading branch information
stephen-swensen committed Mar 8, 2015
1 parent be08e74 commit ef12245
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions UnquoteTests/EvaluationTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ let ``TryFinally no exception try body returned and finally is called`` () =
let ``TryFinally exception is thrown and finally is called`` () =
let finallyCalled = ref false
raises<exn> <@ try
raise (System.Exception())
raise (new System.ArgumentException())
finally
finallyCalled := true @>
test <@ !finallyCalled @>
Expand All @@ -378,7 +378,7 @@ let ``TryWith no exception thrown`` () =
[<Fact>]
let ``TryWith exception thrown no binding or filtering`` () =
testEval <@ try
raise (exn())
raise (new System.ArgumentException())
false
with _ ->
true @>
Expand Down
2 changes: 1 addition & 1 deletion UnquoteTests/ReductionTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,7 @@ let ``ForIntegerRangeLoop reduces range start and end but not body``() =
let ``Issue 62: TryWith with block is followed when exception in body`` () =
let called = ref false
reduceFully <@ try
raise (exn())
raise (new System.ArgumentException())
with e ->
called := true @>
test <@ !called @>
Expand Down

0 comments on commit ef12245

Please sign in to comment.