File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -5951,12 +5951,15 @@ let isRecdOrStructTyconRefAssumedImmutable (g: TcGlobals) (tcref: TyconRef) =
59515951
59525952let isTyconRefReadOnly g m ( tcref : TyconRef ) =
59535953 tcref.CanDeref &&
5954- match tcref.TryIsReadOnly with
5955- | ValueSome res -> res
5956- | _ ->
5957- let res = TyconRefHasAttribute g m g.attrib_ IsReadOnlyAttribute tcref
5958- tcref.SetIsReadOnly res
5959- res
5954+ if
5955+ match tcref.TryIsReadOnly with
5956+ | ValueSome res -> res
5957+ | _ ->
5958+ let res = TyconRefHasAttribute g m g.attrib_ IsReadOnlyAttribute tcref
5959+ tcref.SetIsReadOnly res
5960+ res
5961+ then true
5962+ else tcref.IsEnumTycon
59605963
59615964let isTyconRefAssumedReadOnly g ( tcref : TyconRef ) =
59625965 tcref.CanDeref &&
You can’t perform that action at this time.
0 commit comments