[pygobject/py3k: 8/20] Modify codegen code to run under either Python 2.x or 3.x
- From: John Ehresman <jpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject/py3k: 8/20] Modify codegen code to run under either Python 2.x or 3.x
- Date: Thu, 15 Apr 2010 17:49:41 +0000 (UTC)
commit 8661f934abf276d71b5bf17b617f425a4fc6f06e
Author: John Ehresman <jpe wingware com>
Date: Tue Apr 13 11:49:18 2010 -0400
Modify codegen code to run under either Python 2.x or 3.x
codegen/docextract.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/codegen/docextract.py b/codegen/docextract.py
index eff8c5e..06a08a3 100644
--- a/codegen/docextract.py
+++ b/codegen/docextract.py
@@ -422,10 +422,10 @@ def parse_tmpl(fp, doc_dict):
cur_doc = None # don't worry about unused params.
elif cur_doc:
if line[:10] == '@Returns: ':
- if string.strip(line[10:]):
+ if line[10:].strip():
cur_doc.append_to_return(line[10:])
elif line[0] == '@':
- pos = string.find(line, ':')
+ pos = line.find(':')
if pos >= 0:
cur_doc.append_to_named_param(line[1:pos], line[pos+1:])
else:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]