On Thu, Apr 29, 2010 at 8:31 AM, Casey Duncan <[email protected]> wrote:
> On Wed, Apr 28, 2010 at 8:11 PM, Joe Wreschnig <[email protected]> 
> wrote:
>> Right now, most pyglet docstrings use ''' (triple single quotes)
>> rather than """ (triple double quotes). Although ''' is valid to
>> delimit Python multiline strings, it confuses a number of syntax
>> highlighters such as Google Code and Emacs. I was going to fix Emacs's
>> highlighter, but in checking the standard
>> [http://www.python.org/dev/peps/pep-0257/], I found:
>>    For consistency, always use """triple double quotes""" around
>> docstrings. Use r"""raw triple double quotes""" if you use any
>> backslashes in your docstrings. For Unicode docstrings, use
>> u"""Unicode triple-quoted strings""".
>>
>> This makes reading parts of the pyglet code extremely difficult, for
>> example http://code.google.com/p/pyglet/source/browse/pyglet/sprite.py#211.
>>
>> So while I may fix Emacs, I think it's also a good idea to fix pyglet.
>> This would be a trivial but very noisy patch, and I'd like at least
>> one other person to agree with me it's a good idea before I go make
>> it. Another option would be to prepare per-file or per-module patches,
>> but my view is that it's usually best to do one giant
>> future-conflict-creating merge instead of several smaller ones.
>
> I think the proper solution is to use a real editor. I suggest vim :P
>
> Also using a real hg hosting service, like bitbucket <wink>
>
> It's retarded that Google implemented their own broken syntax
> highlighting, but there it is.
>
> I'm +0 on this, it does make the code more pep-8 compliant, so that's
> a plus. I could care less about stupid broken tools.

This is PEP-257, which is the docstring specification, not PEP-8,
which is the standard library style guideline. It carries more weight
than the style guideline (though it is still a recommendation and not
the definition of a docstring, which is "a string literal that occurs
as the first statement in a module, function, class, or method
definition").

-- 
You received this message because you are subscribed to the Google Groups 
"pyglet-users" 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/pyglet-users?hl=en.

Reply via email to