diff options
| author | nyamatongwe <devnull@localhost> | 2011-02-28 13:04:34 +1100 | 
|---|---|---|
| committer | nyamatongwe <devnull@localhost> | 2011-02-28 13:04:34 +1100 | 
| commit | b7a1aa5a607fad68f65de0d4426af8f50468f1e0 (patch) | |
| tree | 977ad66b6734e5e873974dd2d84d8718ed582b01 | |
| parent | eaea293d5ed6a06b496867d86bc7e4b41b0f383b (diff) | |
| download | scintilla-mirror-b7a1aa5a607fad68f65de0d4426af8f50468f1e0.tar.gz | |
Avoid shadowed variables as reported by Xcode.
| -rw-r--r-- | lexers/LexCPP.cxx | 1 | ||||
| -rw-r--r-- | lexlib/CharacterSet.h | 4 | ||||
| -rw-r--r-- | src/Document.cxx | 4 | ||||
| -rw-r--r-- | src/Editor.cxx | 9 | 
4 files changed, 8 insertions, 10 deletions
| diff --git a/lexers/LexCPP.cxx b/lexers/LexCPP.cxx index 5331e33a4..f573befaa 100644 --- a/lexers/LexCPP.cxx +++ b/lexers/LexCPP.cxx @@ -441,7 +441,6 @@ void SCI_METHOD LexerCPP::Lex(unsigned int startPos, int length, int initStyle,  	CharacterSet setDoxygen(CharacterSet::setAlpha, "$@\\&<>#{}[]");  	CharacterSet setWordStart(CharacterSet::setAlpha, "_", 0x80, true); -	CharacterSet setWord(CharacterSet::setAlphaNum, "._", 0x80, true);  	if (options.identifiersAllowDollars) {  		setWordStart.Add('$'); diff --git a/lexlib/CharacterSet.h b/lexlib/CharacterSet.h index 18cb0aa93..72405606a 100644 --- a/lexlib/CharacterSet.h +++ b/lexlib/CharacterSet.h @@ -50,8 +50,8 @@ public:  		assert(val < size);  		bset[val] = true;  	} -	void AddString(const char *CharacterSet) { -		for (const char *cp=CharacterSet; *cp; cp++) { +	void AddString(const char *setToAdd) { +		for (const char *cp=setToAdd; *cp; cp++) {  			int val = static_cast<unsigned char>(*cp);  			assert(val >= 0);  			assert(val < size); diff --git a/src/Document.cxx b/src/Document.cxx index c0290936f..34e6a99f3 100644 --- a/src/Document.cxx +++ b/src/Document.cxx @@ -1522,8 +1522,8 @@ void Document::EnsureStyledTo(int pos) {  		IncrementStyleClock();  		if (pli && !pli->UseContainerLexing()) {  			int lineEndStyled = LineFromPosition(GetEndStyled()); -			int endStyled = LineStart(lineEndStyled); -			pli->Colourise(endStyled, pos); +			int endStyledTo = LineStart(lineEndStyled); +			pli->Colourise(endStyledTo, pos);  		} else {  			// Ask the watchers to style, and stop as soon as one responds.  			for (int i = 0; pos > GetEndStyled() && i < lenWatchers; i++) { diff --git a/src/Editor.cxx b/src/Editor.cxx index 865633be3..f792d160f 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -705,14 +705,14 @@ void Editor::SetRectangularRange() {  		if (sel.selType == Selection::selThin) {  			xCaret = xAnchor;  		} -		int lineAnchor = pdoc->LineFromPosition(sel.Rectangular().anchor.Position()); +		int lineAnchorRect = pdoc->LineFromPosition(sel.Rectangular().anchor.Position());  		int lineCaret = pdoc->LineFromPosition(sel.Rectangular().caret.Position()); -		int increment = (lineCaret > lineAnchor) ? 1 : -1; -		for (int line=lineAnchor; line != lineCaret+increment; line += increment) { +		int increment = (lineCaret > lineAnchorRect) ? 1 : -1; +		for (int line=lineAnchorRect; line != lineCaret+increment; line += increment) {  			SelectionRange range(SPositionFromLineX(line, xCaret), SPositionFromLineX(line, xAnchor));  			if ((virtualSpaceOptions & SCVS_RECTANGULARSELECTION) == 0)  				range.ClearVirtualSpace(); -			if (line == lineAnchor) +			if (line == lineAnchorRect)  				sel.SetSelection(range);  			else  				sel.AddSelectionWithoutTrim(range); @@ -4733,7 +4733,6 @@ void Editor::Duplicate(bool forLine) {  		forLine = true;  	}  	UndoGroup ug(pdoc, sel.Count() > 1); -	SelectionPosition last;  	const char *eol = "";  	int eolLen = 0;  	if (forLine) { | 
