Opened 10 years ago

Closed 9 years ago

#486 closed defect (fixed)

Disable long indention under quantifiers?

Reported by: coquser Owned by: courtieu
Priority: minor Milestone: PG-Emacs-4.3
Component: 3:pg-broker Keywords:
Cc: gmalecha@…

Description

At some point (I think related to emacs 24) Proof General changed its way for indenting lines under quantifiers. E.g.

Lemma foo_bar_baz : forall x y z,

x = y -> y = z -> x = z.

Is there a way to revert to the previous 2-space indent from the indent at the beginning of the line?

Change History (3)

comment:1 Changed 9 years ago by coquser

The following patch does what you want. It's for Pierre to decide whether this should be applied to trunk or not :)

--- coq-smie.el.~11.21.~	2015-04-21 17:55:18.203475436 -0400
+++ coq-smie.el	2015-04-27 13:12:10.283113723 -0400
@@ -927,7 +927,7 @@
        ((and (member token '("forall" "quantif exists"))
 	     (not coq-indent-box-style)
 	     (not (smie-rule-bolp)))
-	(smie-rule-parent 2))
+	(smie-rule-parent 0))
 
        ;; trying to indent "{" at the end of line for records, but the
        ;; parent is not what I think.

comment:2 Changed 9 years ago by courtieu

Owner: changed from Christoph Lueth to courtieu
Status: newassigned

Hi,

The idea (from smie) of the 4 space characters is the following:

Lemma foo_bar_baz : forall x y z,

x = y -> y = z -> x = z.

indents the last line at the same column than in :

Lemma foo_bar_baz :

forall x y z,

x = y -> y = z -> x = z.

I will try to have an option for that.

comment:3 Changed 9 years ago by courtieu

Resolution: fixed
Status: assignedclosed

done.

Note: See TracTickets for help on using tickets.