Soilihi BEN SOILIHI BOINA pushed to branch diagnostics_and_hover at Stefan / Typer
Commits: 9cfd9dce by Soilih at 2022-02-07T14:48:33-05:00 -
- - - - - 3e8d5a43 by Soilih at 2022-02-08T16:24:08-05:00 -
- - - - - 27799cdd by Soilih at 2022-02-09T10:02:53-05:00 -
- - - - - 9aea8c6e by Soilih at 2022-02-09T21:31:44-05:00 correcting the hover
- - - - -
2 changed files:
- src/log.ml - src/typer_lsp_server.ml
Changes:
===================================== src/log.ml ===================================== @@ -228,7 +228,7 @@ let handle_error ~(on_error : unit -> 'a) (action : unit -> 'a) : 'a = let log_fatal ?section ?print_action ?loc fmt = typer_log_config.print_at_log <- true; log_msg - (fun _ -> internal_error "Compiler Fatal Error") + (fun s -> internal_error "Compiler Fatal Error: %s" s) Fatal ~kind:"[X] Fatal " ?section
===================================== src/typer_lsp_server.ml ===================================== @@ -775,12 +775,8 @@ class lsp_server = let ctx = Debruijn.ectx_to_lctx (Elab.default_ectx) in let lexp = trans_list_in_list_to_let list_list in
- let (lctx,vx) = lexp_search ctx list_list typer_loc in - let ((lvn,_),_,ltyp) = vx in - - let (l_ctx_r,_,_,_) as ret = browse_lexp ctx lexp typer_loc in - let ret' = (l_ctx_r,None,ltyp,lvn) in - let (l_ctx,_,l_type,location) = browse_list_lexp [ret;ret'] typer_loc in + let (l_ctx,_,l_type,location) = browse_lexp ctx lexp typer_loc in + let location' = { location with @@ -792,7 +788,6 @@ class lsp_server = let s = try use_search_name_in_ctx l_ctx l_type with exe -> Lexp.lexp_string_for_lsp l_type in - (*let s = Lexp.lexp_string_for_lsp l_type in*) let r = Lsp.Types.Hover.create ~contents:(`MarkedString {Lsp.Types.MarkedString.value=s; language=(Some "Typer")}) ~range:range ()
View it on GitLab: https://gitlab.com/monnier/typer/-/compare/ca17860aa69e0b15b37f75f299d15eb64...
Afficher les réponses par date