Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does ^L in (Emacs Lisp) source code mean?

Several times I see ^L in (mostly Emacs Lisp) source codes that looks like are separators of larger logical groups. Is it their real purpose? And if so, how can I use them? Is there a built-in Emacs functionality that utilize it?

like image 220
viam0Zah Avatar asked Oct 16 '09 08:10

viam0Zah


People also ask

What is Emacs Lisp used for?

Emacs Lisp is a dialect of the Lisp programming language used as a scripting language by Emacs (a text editor family most commonly associated with GNU Emacs and XEmacs). It is used for implementing most of the editing functionality built into Emacs, the remainder being written in C, as is the Lisp interpreter.

Is Emacs functional Lisp?

Emacs Lisp supports multiple programming styles or paradigms, including functional and object-oriented. Emacs Lisp is not a purely functional programming language since side effects are common. Instead, Emacs Lisp is considered an early functional flavored language.

Is Emacs Lisp the same as Lisp?

By default, Common Lisp is lexically scoped, that is, every variable is lexically scoped except for special variables. By default, Emacs Lisp files are dynamically scoped, that is, every variable is dynamically scoped.


1 Answers

The Emacs commands backward-page and forward-page (C-x [ and C-x ]), among others, take advantage of ^Ls placed in the code as separators.

The habit did not propagate much to languages other than Emacs-lisp, but most languages treat ^L as a blank, so you can use these separators in your favorite language if you like the idea. You can type your own ^Ls with C-q C-l.

like image 192
Pascal Cuoq Avatar answered Oct 02 '22 10:10

Pascal Cuoq