IntegratedDynamics icon indicating copy to clipboard operation
IntegratedDynamics copied to clipboard

String format function

Open Shovinus opened this issue 6 years ago • 3 comments

Issue type:

  • :heavy_plus_sign: Feature request

Short description:

Allow the building of string with placeholders and variables: "Hello {0}, you have {1} new messages." Then pass in variables. If it could accept multiple variable cards that would be nice.

Shovinus avatar Jul 04 '18 10:07 Shovinus

Should be trivial to implement with a fixed number of variables, but a bit more tricky with a variable number of variables (but a list could work here).

rubensworks avatar Jul 04 '18 10:07 rubensworks

no more than 10 would normally needed but even then you can just concat more.

Shovinus avatar Jul 04 '18 13:07 Shovinus

If considered to make a .NET style string format operator here is the .NET string class and format function https://github.com/microsoft/referencesource/blob/master/mscorlib/system/string.cs#L2960

GitHub
Source from the Microsoft .NET Reference Source that represent a subset of the .NET Framework - microsoft/referencesource

Flithor avatar Jun 25 '19 08:06 Flithor