mirror of
https://github.com/dmolony/DiskBrowser.git
synced 2025-02-06 04:29:56 +00:00
keep parameters out of call target
This commit is contained in:
parent
6a1f7043cb
commit
506742bbac
@ -331,7 +331,7 @@ public class SubLine implements ApplesoftConstants
|
||||
break;
|
||||
|
||||
case TOKEN_CALL:
|
||||
callTarget = getExpression ();
|
||||
callTarget = getCallTarget ();
|
||||
break;
|
||||
|
||||
case TOKEN_DEF:
|
||||
@ -398,7 +398,7 @@ public class SubLine implements ApplesoftConstants
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------------//
|
||||
private String getExpression ()
|
||||
private String getCallTarget ()
|
||||
// ---------------------------------------------------------------------------------//
|
||||
{
|
||||
StringBuilder text = new StringBuilder ();
|
||||
@ -410,6 +410,8 @@ public class SubLine implements ApplesoftConstants
|
||||
byte b = buffer[ptr++];
|
||||
if (isToken (b))
|
||||
text.append (tokens[b & 0x7F]);
|
||||
else if (b == Utility.ASCII_COMMA) // end of call target
|
||||
break;
|
||||
else
|
||||
text.append ((char) b);
|
||||
}
|
||||
@ -576,7 +578,7 @@ public class SubLine implements ApplesoftConstants
|
||||
if (isFirst ())
|
||||
{
|
||||
text.setLength (0);
|
||||
text.append (String.format (" %d REM ", parent.lineNumber));
|
||||
text.append (String.format (" %d REM ", parent.lineNumber)); // mimic apple
|
||||
}
|
||||
else
|
||||
text.append ("REM ");
|
||||
|
@ -25,6 +25,7 @@ public class Utility
|
||||
public static final byte ASCII_PERCENT = 0x25;
|
||||
public static final byte ASCII_LEFT_BRACKET = 0x28;
|
||||
public static final byte ASCII_RIGHT_BRACKET = 0x29;
|
||||
public static final byte ASCII_COMMA = 0x2C;
|
||||
public static final byte ASCII_MINUS = 0x2D;
|
||||
public static final byte ASCII_DOT = 0x2E;
|
||||
public static final byte ASCII_COLON = 0x3A;
|
||||
|
Loading…
x
Reference in New Issue
Block a user