summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-01-06 04:35:45 +0000
committerZac Medico <zmedico@gentoo.org>2007-01-06 04:35:45 +0000
commitc5fd157e5b4945786b5f82482eb8710b1fd97af2 (patch)
treede750cfa72a3cfe24aa774ccfc844d2f1affdb64 /bin/repoman
parentFor bug #160310, allow \ inside `` quotes in order to prevent a false Line co... (diff)
downloadportage-multirepo-c5fd157e5b4945786b5f82482eb8710b1fd97af2.tar.gz
portage-multirepo-c5fd157e5b4945786b5f82482eb8710b1fd97af2.tar.bz2
portage-multirepo-c5fd157e5b4945786b5f82482eb8710b1fd97af2.zip
For bug #160310, remove the line continuation syntax check since it's still possible for it to generate false positives.
svn path=/main/trunk/; revision=5471
Diffstat (limited to 'bin/repoman')
-rwxr-xr-xbin/repoman19
1 files changed, 0 insertions, 19 deletions
diff --git a/bin/repoman b/bin/repoman
index 50a2e214..88b101bb 100755
--- a/bin/repoman
+++ b/bin/repoman
@@ -1293,8 +1293,6 @@ for x in scanlist:
leading_spaces = re.compile(r'^[\S\t]')
trailing_whitespace = re.compile(r'.*([\S]$)')
readonly_assignment = re.compile(r'^\s*(export\s+)?(A|CATEGORY|P|PV|PN|PR|PVR|PF|D|WORKDIR|FILESDIR|FEATURES|USE)=')
- continuation_symbol = re.compile(r'(.*[ ]+[\\][ ].*)')
- line_continuation_quoted = re.compile(r'(\"|\'|`)(([\w ,:;#\[\]\.`=/|\$\^\*{}()\'-])|(\\.))*\1')
line_continuation = re.compile(r'([^#]*\S)(\s+|\t)\\$')
linenum=0
previous_line = None
@@ -1348,23 +1346,6 @@ for x in scanlist:
myerrormsg = "Readonly variable assignment to %s on line %d" % (match.group(2), linenum)
stats["variable.readonly"] += 1
fails["variable.readonly"].append(x+"/"+y+".ebuild: %s" % myerrormsg)
- # Line continuation check
- match = continuation_symbol.match(line)
- if match:
- #Excluded lines not even containing a " \" match. Good!
- line = re.sub(line_continuation_quoted,"\"\"",line)
- # line has been edited to collapse "", '', and ``
- # quotes to "". Good!
- match = continuation_symbol.match(line)
- if match:
- #Again exclude lines not even containing a " \" match. Good!
- #This repetition is done for a slight performance increase
- match = line_continuation.match(line)
- if not match:
- #Line has a line continuation error. Bad!
- myerrormsg = "Line continuation (\"\\\") Syntax Error. Line %d" % linenum
- stats["ebuild.majorsyn"] +=1
- fails["ebuild.majorsyn"].append(x+"/"+y+".ebuild: %s" % myerrormsg)
previous_line = line
del previous_line