Skip to content

Commit

Permalink
fix: fix lspManager for prior versions of coq (8.18, 8.19, 8.20) and …
Browse files Browse the repository at this point in the history
…test
  • Loading branch information
rtetley committed Nov 19, 2024
1 parent 8eb8c57 commit 9e78309
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions client/src/test/suite/extension.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ suite('Should get diagnostics', function () {

const ext = vscode.extensions.getExtension('maximedenes.vscoq')!;
await ext.activate();
vscode.workspace.getConfiguration().update('vscoq.proof.mode','Continuous');

const doc = await common.openTextFile('basic.v');

Expand All @@ -34,6 +35,7 @@ suite('Should get diagnostics', function () {

const ext = vscode.extensions.getExtension('maximedenes.vscoq')!;
await ext.activate();
vscode.workspace.getConfiguration().update('vscoq.proof.mode','Continuous');

const doc1 = await common.openTextFile('basic.v');
const doc2 = await common.openTextFile('warn.v');
Expand Down
7 changes: 6 additions & 1 deletion language-server/vscoqtop/lspManager.ml
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,12 @@ let open_new_document uri text =
let project = CoqProject_file.read_project_file ~warning_fn:(fun _ -> ()) f in
let args = CoqProject_file.coqtop_args_from_project project in
log (Printf.sprintf "Arguments from project file %s: %s" f (String.concat " " args));
fst @@ Coqargs.parse_args ~init:Coqargs.default args
let usage = {
Boot.Usage.executable_name = "";
extra_args = "";
extra_options = "";
} in
fst @@ Coqargs.parse_args ~init:Coqargs.default ~usage args
in

let vst = init_document local_args vst in
Expand Down

0 comments on commit 9e78309

Please sign in to comment.