help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ELisp Multiline Comments


From: Christopher Dimech
Subject: Re: ELisp Multiline Comments
Date: Sat, 10 Oct 2020 18:11:02 +0200

   Have figured out that the problem originated from the Ascii Art I was
   using, where
   there can appear characters like ( ) etc.

   Commenting the Ascii Art loads the .el file properly.

   Sent: Saturday, October 10, 2020 at 6:07 PM
   From: "Christopher Dimech" <dimech@gmx.com>
   To: "Stefan Monnier" <monnier@iro.umontreal.ca>
   Cc: help-gnu-emacs@gnu.org
   Subject: Re: ELisp Multiline Comments
   Have tried using the following for writing multiline comments, but has
   worked.
   (defmacro multic (&rest _) nil)
   ;;; gungadin-frame.el --- Customisations for Emacs Frame
   ( multic
   * Copyright and License
   ;;;;
   ====================================================================
   ;;;; Copyright and License
   ;;;;
   ====================================================================
   ___ _ _
   / __|_ __ _ _ | | (_)__
   | (__| '_ \ '_| | |__| / _|
   \___| .__/_| |____|_\__|
   |_|
   )
   ;; Copyright 2017 Christopher Dimech
   ;; GNU Affero General Public License, Version 3 or any later version
   Sent: Saturday, October 10, 2020 at 4:46 PM
   From: "Stefan Monnier" <monnier@iro.umontreal.ca>
   To: help-gnu-emacs@gnu.org
   Subject: Re: ELisp Multiline Comments
   > I need to use Multiline Comments in my Elisp Codes so I can insert
   > Org-Mode Commands,
   > and read you can use
   >
   > #|
   > Multiline Comment
   > |#
   >
   > What are the options
   ELisp does not support multiline comments.
   You have two options:
   - Use `;;` and make sure to either ignore them or strip them when using
   the
   comments's content:
   ;; Multiline
   ;; Comment
   - Use unused arguments, e.g.:
   (defmacro multiline-comment (&rest _) nil)
   ...
   (multiline-comment
   Multiline
   Comment
   )
   and then make sure you use those uses of `multiline-comment` only
   occur where an ELisp expression is expected (e.g. not within the
   arglist of a function) and make sure the text of those multiline
   comments corresponds to a valid read syntax of some ELisp data
   (e.g. properly matched parentheses and double quotes (but without
   counting those parens that occur after a semi-colon), no single quote
   just before an open paren, ...).
   I'd go with the first option.
   Stefan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]