Compiling SRL went from 450ms to 280ms.
I think the only other related optimization worth doing in the future would be not compiling method statement list if the method is never used.
Changes:
TLapeDeclCollection is now an abstract class.
TLapeDeclarationList uses TLapeDeclCollection_Dictionary by default. There remains TLapeDeclCollection_List for when normal indexing is required which is currently only TLapeType_OverloadedMethod.
Added TLapeUniqueDictionary which is a dictionary where each bucket can only have one value. TLapeCompiler.getBaseType(Name: lpString) and Lape_IsKeyword now use this.
Optimized TLapeCompiler.getConstant and usage of it.
TLapeParser.IdentifyAlpha() no longer appends character by character. getTokString is now called once at the end.
Removed some compiling hints.
Compiling SRL went from
450ms
to280ms
. I think the only other related optimization worth doing in the future would be not compiling method statement list if the method is never used.Changes:
TLapeDeclCollection
is now an abstract class.TLapeDeclarationList
usesTLapeDeclCollection_Dictionary
by default. There remainsTLapeDeclCollection_List
for when normal indexing is required which is currently onlyTLapeType_OverloadedMethod
.Added
TLapeUniqueDictionary
which is a dictionary where each bucket can only have one value.TLapeCompiler.getBaseType(Name: lpString)
andLape_IsKeyword
now use this.Optimized
TLapeCompiler.getConstant
and usage of it.TLapeParser.Identify
Alpha()
no longer appends character by character.getTokString
is now called once at the end. Removed some compiling hints.