As already described, single-line comments in Lisp are introduced by a semi-colon (`;') character. By convention a different number of semi-colons is used to introduce different types of comments,
(defconst op-call 0x08) ;call (stk[n] stk[n-1] ... stk[0])
; pops n values, replacing the
; function with the result.
(defconst op-push 0x10) ;pushes constant # n
;; Be sure to remove any partially written dst-file.
(let
((fname (concat file-name ?c)))
(when (file-exists-p fname)
(delete-file fname)))
Comments of this type are also placed before a function definition
to describe the function. This saves wasting memory with a documentation
string in a module's internal functions.
For example,
;; Compile a form which occurred at the `top-level' into a ;; byte code form. ;; defuns, defmacros, defvars, etc... are treated specially. ;; require forms are evaluated before being output uncompiled; ;; this is so any macros are brought in before they're used. (defun comp-compile-top-form (form) ...
;;; Notes: ;;; ;;; Instruction Encoding ;;; ==================== ;;; Instructions which get an argument (with opcodes of zero up to ...
;;;; compiler.jl -- Simple compiler for Lisp files/forms
If you adhere to these standards the indentation functions provide by the Lisp mode will indent your comments to the correct depth.
Go to the first, previous, next, last section, table of contents.