mirror of
https://github.com/dmolony/DiskBrowser.git
synced 2024-06-01 03:41:29 +00:00
remove duplicate lines
This commit is contained in:
parent
51a98398ca
commit
dd89855d64
|
@ -764,8 +764,6 @@ public class ApplesoftBasicProgram extends BasicProgram
|
|||
if (is (TOKEN_REM))
|
||||
return;
|
||||
|
||||
// System.out.println (this);
|
||||
|
||||
int ptr = startPtr;
|
||||
length--;
|
||||
String var = "";
|
||||
|
@ -802,14 +800,20 @@ public class ApplesoftBasicProgram extends BasicProgram
|
|||
|
||||
if (isLetter ((byte) var.charAt (0)))
|
||||
{
|
||||
// System.out.printf (" Var: %s%n", var);
|
||||
List<Integer> lines = symbolLines.get (var);
|
||||
if (lines == null)
|
||||
{
|
||||
lines = new ArrayList<> ();
|
||||
symbolLines.put (var, lines);
|
||||
}
|
||||
lines.add (parent.lineNumber);
|
||||
if (lines.size () == 0)
|
||||
lines.add (parent.lineNumber);
|
||||
else
|
||||
{
|
||||
int lastLine = lines.get (lines.size () - 1);
|
||||
if (lastLine != parent.lineNumber)
|
||||
lines.add (parent.lineNumber);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user