Procedure ParseTheText(Const SourceText:AnsiString; MyResult: MyType);I assume you mean "; var MyResult: MyType"?
I just thought that doing it as a function might make two variables.Yes, it is. So using a procedure instead of a function will allow you to do this micro-optimization. Example: use the SysUtils FmtStr function instead of the Format function.
Ie... first the function fills up the "Result"-variable of the chosen type.
Then the "Result"-variable is copied into MyResult.