Re: [cc65] ca65html and anonymous labels

From: MagerValp <MagerValp1cling.gu.se>
Date: 2006-09-22 00:16:22
>>>>> "UvB" == Ullrich von Bassewitz <uz@musoftware.de> writes:

MV> ca65html incorrectly parses
MV> 
MV> bne :-
MV> 
MV> as a label named "bne". ca65 apparently allows whitespace around
MV> the label name, and the ca65html regexp is a little too greedy. As
MV> I don't use that particular feature myself (does anyone?), I
MV> hacked the regexp to only allow spaces before =, and not before :.

UvB> There must be a better solution (only accept the ':' if it is not
UvB> followed by '+' or '-').

Probably, this was just a quick hack to get it to handle my sources.
There's actually another false positive now, label:= value.

I wasn't sure how to match something that isn't followed by a
particular pattern, but google tells me:

  (?!...)

    This is a "look ahead" thing and always comes after some other
    part of the regular expression. It means, match the stuff before
    me only if it is not followed by "...".

Btw, would it be possible to add an option (in da65) that only
includes referenced labels at the top? I'm including a full list of
kernal labels in some disassemblies, and it would be handy if da65
only kept those definitions that are referenced.

MV> I also made it output valid HTML 4.01 Strict + CSS when
MV> colorizing. Patch is here:
MV> 
MV> http://www.paradroid.net/tmp/ca65html.patch

UvB> Whow, nice work! Can I integrate this into the official version?

Of course.

I also thought about adding a few more classes (mnemonics, control
commands, etc), but decided it was too much work. I won't complain if
you add that though :)

-- 
    ___          .     .  .         .       . +  .         .      o   
  _|___|_   +   .  +     .     +         .  Per Olofsson, arkadspelare
    o-o    .      .     .   o         +          MagerValp@cling.gu.se
     -       +            +    .     http://www.cling.gu.se/~cl3polof/
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Fri Sep 22 00:16:35 2006

This archive was generated by hypermail 2.1.8 : 2006-09-22 00:16:37 CEST