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

Unbalanced Parentheses in Comment Blocks (a'la #|...|#)



I have an intermitent problem with Zmacs.  On occasion I use open and close
parentheses within my Lisp file comment blocks (see the below example).
However, Zmacs flags these parens as unbalanced; therefore, checking for
unbalanced parens during saving is useless.  Does anyone know how to turn
the paren checker within comment blocks.  [I originally thought that single-bar
comment blocks, #| ... |#, did not check paren balance, but that double-bar
comment blocks, #|| ... ||#, was to be used if paren checking were desired.

#|---------------------------------------------------------------------------------------------
unit-icosahedron &key tolerance							     [Function]
Argument List: 
Keyword Arguments:
  tolerance type: Float
	    purpose: this determines the tolerance in our iterations
Purpose: 
Algorithm:
  1) guess L  [1>L>>0]
  2) "determine L1"
     2.1) guess L1  [L>L1>>0]
     2.2) let Pentagon = {N=0..4 | E(N) = L1cos(2Npi/5) + L1sin(2Npi/5)i}
     2.3) if distance(E(0),E(1))~=L,
	     then stop returning [L1, L2=sqrt(L^2-L1^2)];
	     otherwise, L1.new is L1+(D-L)/2 (?) and go to step 2.2
  3) let Pentagon(blue) = {N=0..4 | Eb(N) = L2 + L1cos(2Npi/5)i + L1sin(2Npi/5)j}
	 Pentagon(red)  = {N=0..4 | Er(N) = -L2 - L1cos(2Npi/5)i + L1sin(2Npi/5)j}
  4) if distance(Eb(0),Er(2))~=L,
	then stop returning [L, Icoshedron object];
	otherwise, L.new is L+(D-L)/2 (?), and go to step 2
Implementation:
  The implementation of the above algorithm in Lisp is quite easily done with recursion.
  Step #2 and Steps #2-3 can be implemented as self-recursing functions; called determine-L1
  and determine-L, respectively.
|#;;;;
(defun unit-icosahedron (&key (tolerance 0.001))
   ...)

Any clues?	Bryan

/-------------------------------------------------/
/  Bryan D. Basham				  /
/  NASA/JSC  Mail Stop: ER22,  Houston TX  77058  /
/  (713) 483-2065				  /
/  Basham@AIO.JSC.NASA.GOV			  /
/-------------------------------------------------/