2 new comment-like characters in Python to aid development?

Nick Craig-Wood nick at craig-wood.com
Fri Mar 9 08:30:08 EST 2007


Robert Marshall <spam at chezmarshall.freeserve.co.uk> wrote:
>  On Fri, 09 Mar 2007, Bruno Desthuilliers wrote:
> 
> > 
> > Nick Craig-Wood a ?crit :
> >> dbhbarton at googlemail.com <dbhbarton at googlemail.com> wrote:
> >>>  What if 2 new 'special' comment-like characters were added to
> >>>  Python?:
> >>>
> >>>
> >>>  1. The WIP (Work In Progress) comment:
> >>
> >> I use # FIXME for this purpose or /* FIXME */ in C etc.
> >>
> >> I have an emacs macro which shows it up in bright red / yellow text
> >> so it is easy to see
> > 
> > <ot>
> > Care to share this macro ?
> > </ot>
> 
>  I have this
> 
>  (cond (window-system
>     (progn
>       (font-lock-add-keywords 
>          'python-mode '(("\\<FIXME: .*$" 0 font-lock-warning-face prepend))))))

This is what I use which is very similar

(font-lock-add-keywords 'python-mode
  '(
    ("\\<\\(FIXME\\):?" 1 font-lock-warning-face prepend)
    )
  )

-- 
Nick Craig-Wood <nick at craig-wood.com> -- http://www.craig-wood.com/nick



More information about the Python-list mailing list