1234567891011121314151617181920212223242526272829303132333435363738394041424344(************************************************************************)(* * The Rocq Prover / The Rocq Development Team *)(* v * Copyright INRIA, CNRS and contributors *)(* <O___,, * (see version control and CREDITS file for authors & dates) *)(* \VV/ **************************************************************)(* // * This file is distributed under the terms of the *)(* * GNU Lesser General Public License Version 2.1 *)(* * (see LICENSE file for the text of the license) *)(************************************************************************)(* Quickfix management *)typet=Loc.t*Pp.tletmake~loctxt=loc,txtletpp(_,x)=xletpp_wloc(loc,x)=letopenPpinh(str"Replace "++Loc.prloc++str" with "++x)letloc(l,_)=llethandle_stack=ref[]letregisterh=handle_stack:=h::!handle_stackletrecaccumulate_qfaccstke=matchstkwith|[]->acc|h::stk->accumulate_qf(he::acc)stkeletfrom_exceptione=tryOk(CList.flatten(accumulate_qf[]!handle_stacke))withexn->letei=Exninfo.captureexninErroreiletprinte=letopenPpinmatchewith|[]->mt()|qf->letopenPpinletqf=prlist_with_sepcutpp_wlocqfinv0(prlist_with_sepcut(funx->x)[str"Quickfix:";qf])