Dmitry Boyarintsev schrieb:
How about introducing a default parameter?
The parameter keeps the method backward compatible, allowing write a string without the prefix.

public procedure TStream.WriteAnsiString(
  const S: string;
  withLength: Boolean = true;

How should a string without a length be read back?

DoDi

_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to