MCPcopy Create free account
hub / github.com/RetiredWizard/PyDOS / getprogram

Method getprogram

PyBasic/program.py:271–279  ·  view source on GitHub ↗
(self, ln, infile, tmpfile)

Source from the content-addressed store, hash-verified

269 return line_numbers
270
271 def getprogram(self, ln, infile, tmpfile):
272 if self.__program[ln] >= 0:
273 infile.seek(self.__program[ln])
274 statement = Lexer().tokenize((infile.readline().strip().replace("\n","")).replace("\r",""))[1:]
275 else:
276 tmpfile.seek(-(self.__program[ln]+1))
277 statement = Lexer().tokenize((tmpfile.readline().replace("\n","")).replace("\r",""))[1:]
278
279 return statement
280
281 def __execute(self, line_number, infile,tmpfile):
282 """Execute the statement with the

Callers 4

listMethod · 0.95
saveMethod · 0.95
__executeMethod · 0.95
executeMethod · 0.95

Calls 2

LexerClass · 0.90
tokenizeMethod · 0.80

Tested by

no test coverage detected