Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to initialize empty hint database

I have several proofs that follow identical structure. First of them can be finished with trivial, all the other ones with auto with foo_db, where foo_db is a hint database populated with hints after the first proof is complete. I'd like to write an Ltac procedure that uses auto with foo_db to solve all these proofs. However, when running that Ltac to solve the first of my proofs foo_db does not yet exist and so Coq complains: Error: No such Hint database: foo_db.. Is there a way to initialize an empty hint database?

like image 261
Jan Stolarek Avatar asked Mar 10 '26 22:03

Jan Stolarek


1 Answers

Yes, there's a command Create HintDb that does exactly what you want.

Create HintDb foo_db.

Goal True.
  auto with foo_db nocore. (* no hints *)
  exact I.
Qed.

For demonstration purposes (to avoid solving the goal), I've also added the pseudo-db nocore to avoid using the standard library's hints. You probably want to just do auto with foo_db, to solve all the goals trivial would have solved.

like image 141
Tej Chajed Avatar answered Mar 15 '26 02:03

Tej Chajed



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!