Skip to content

Commit

Permalink
Use unelaborated syntax for ExplainThis
Browse files Browse the repository at this point in the history
  • Loading branch information
7h3kk1d committed Dec 27, 2024
1 parent bd36673 commit 7158c4a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/haz3lcore/statics/Info.re
Original file line number Diff line number Diff line change
Expand Up @@ -797,3 +797,13 @@ let typ_is_constructor_expected = t =>
| {expects: ConstructorExpected(_) | VariantExpected(_), _} => true
| _ => false
};

let rec unelaborated_info = (info: t): t =>
switch (info) {
| InfoExp({unelaborated_info: ui, _}) =>
switch (ui) {
| Some(info) => unelaborated_info(InfoExp(info))
| None => info
}
| _ => info
};
1 change: 1 addition & 0 deletions src/haz3lweb/view/ExplainThis.re
Original file line number Diff line number Diff line change
Expand Up @@ -2496,6 +2496,7 @@ let view =
~explainThisModel: ExplainThisModel.t,
info: option(Info.t),
) => {
let info = Option.map(Info.unelaborated_info, info);
let (syn_form, (explanation, _), example) =
get_doc(
~docs=explainThisModel,
Expand Down

0 comments on commit 7158c4a

Please sign in to comment.