The current testsuite says that in sweet-expressions the following should mean 
"(foo (a b) . c)":
foo
!  a b
!  .
!  c

SHOULD it mean that?  My ANTLR BNF doesn't do that, it just treats lone "." as 
a period, but we *did* support that previously.

It also has said that lone abbreviation on a line, followed by an indent, 
applies that abbreviation to the body. E.G., this would mean "(quote (aaa 
bbb))":
'
! (aaa bbb)

Again, my ANTLR BNF doesn't do that, but we used to.  This one is debatable, 
since you can get the same effect with the word "quote" in Scheme (though that 
reasoning doesn't apply to Common Lisp).

I've tweaked the ANTLR BNF so that initially-indented special comments are 
consumed, with the following hspace consumed too, and then recurses back to the 
t_expr production, like this:
   | (FF | VT)+ EOL retry2=t_expr {$v=$retry2.v;}
   | (initial_indent_no_bang | hspace+ )
     (n_expr {$v = $n_expr.v;} /* indent processing disabled */
+     | scomment hspace* sretry=t_expr {$v=$sretry.v;}
      | comment_eol retry3=t_expr {$v=$retry3.v;} )
   | initial_indent_with_bang error
   | EOF {generate_eof();} /* End of file */
This is so that initially-indented block comments don't quietly disable 
sweet-expressions in the next line, like this:
  #|  Hello |#
  foo bar
I think should be "(foo bar)" not "foo" then "bar".

Comments? Thoughts?

 --- David A. Wheeler


------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnnow-d2d
_______________________________________________
Readable-discuss mailing list
Readable-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/readable-discuss

Reply via email to