Log of the #nice channel on irc.freenode.net

Using timezone: Greenwich Mean Time
<bonniot>so arjan, will you be interested in looking at modifying the parser for nicedoc?01:01
<arjanb>i can try that01:02
<bonniot>some parts should be shared with the main parser01:04
<arjanb>almost everything will be the same01:05
<bonniot>yes, and all the part about expressions is not needed
<arjanb>not true01:06
because of default values
<bonniot>well, you need to somehow parse to find the end and begning of declarations01:07
default values, yes, they might probably be part of the doc
like a boolean arg, it's useful to know it has a default value of false01:08
so you're right
when we have such a parser, the compilation API will need to offer the option to choose a parser01:09
then the rest is Frank's :-)01:11
<arjanb>it might be even easier to have only one parser01:12
<bonniot>we don't want doc comments in the compiler's parser01:14
<arjanb>just a flag whether to store the doc comments01:15
<bonniot>it's a possibility, but then you would need to mesure that there is no slow-down01:17
one thing that would be neat is the possibility to nest comments01:18
so that there can be
. /*
. blah blah
. /** doc comment */
. foo
. */
in Java, foo is not commented, and then */ is an error01:19
it's impractical, when you want to comment a large section, that already contains short comments
i don't know if that can be done in JavaCC's lexer, or if it needs to get to the parser level01:20
did you never miss that semantics for comments?01:21
<arjanb>yes
we will see if i can win the strugle with the lexer01:22
<bonniot>:-)
read the docs, too :-)
<arjanb>i will but lexers are always the ugliest part a of parser generator01:23
<bonniot>ok, so good luck! :-)01:37
good night
<arjanb>good night
* bonniot leaves
* arjanb leaves02:05
* arjanb joins13:41
* bonniot joins22:36
hi
<arjanb>hi
<bonniot>how are you doing?22:37
<arjanb>getting nicedoc comments from the parser is very easy22:38
and nested comments are not really possible with javacc
<bonniot>are you sure about that last one?22:39
<arjanb>the lexer of javacc uses a dfa22:40
<bonniot>so?22:41
<arjanb>so only regular expressions
i can workaround by defining a lexical state for every level of nesting of comments22:42
but that has to be limited to some value22:43
<bonniot>look at this: http://www.cs.albany.edu/~sreeni/JavaCC/aprilmail/101.html
it uses lexical states, but does not seem limited22:44
(google is your friend :-)
<arjanb>in that case a variable is used as kind of a stack so you can do context free things as nested comments22:45
<bonniot>is that a problem?22:46
<arjanb>no :-)22:47
<bonniot>:-)22:48
i'm looking at typing Object22:54
<arjanb>i have nested comments working now23:19
<bonniot>great!23:21
* rems joins23:35
<bonniot>just wrote some code where I did if (x == MyClass.instance)23:38
while i should have done if (x == MyOtherClass.instance)
Nice would have caught it autoamtically :-)23:39
* rems leaves
<bonniot>there should be a testcase for nested comments00:38
<arjanb>added00:44
<bonniot>thanks
* Bluelive leaves01:16
* Bluelive joins01:17
* bonniot leaves01:21
* bonniot joins
* bonniot leaves01:22
* Bluelive leaves
* arjanb leaves
* ChanServ leaves
* ChanServ joins
* bonniot joins
* arjanb joins
* Bluelive joins
* ChanServ leaves01:27
* ChanServ joins
* ChanServ leaves01:28
* ChanServ joins01:29