Would it be acceptable to default to "@language plain" instead of
"@language unknown_language", which (without looking at the code) I'm
going to guess would set self.startSentinelComment to "#" instead of
undefined?   And then we could override that with the closest ancestor
"@language" or "@delims" statement?

Another question: how do/should we handle Leo guessing the language
wrong?  E.g., ".pl" is the suffix for both perl and prolog; Unix
actually doesn't care - there's either the magic bytes of a binary
executable at the beginning (in which case the convention is not to
have a suffix), or "#! /path/to/interpreter" if the file is
interpretable by a scripting language.  Any other interpretation is
the application's responsibility, so we get to invent the rules
ourselves.

    - Stephen

On Oct 23, 7:07 am, "Edward K. Ream" <[EMAIL PROTECTED]> wrote:
> On Thu, Oct 23, 2008 at 2:21 AM, thyrsus <[EMAIL PROTECTED]> wrote:
>
> Thanks for this report.
>
> > with the headline "@shadow CHANGELOG"
>
> [snip]
>
> >  File "/usr/local/lib/leo/core/leoAtFile.py", line 3136, in
> > putCodeLine
> >    if g.match(s,k,self.startSentinelComment + '@'):
> > TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
>
> The last line of a traceback is telling us that
> self.startSentinelComment is None, presumably because the file has no
> extension.  I'll fix this bug soon.
>
> Edward
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/leo-editor?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to