Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • openfoam openfoam
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 413
    • Issues 413
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 7
    • Merge requests 7
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Development
  • openfoamopenfoam
  • Issues
  • #724
Closed
Open
Issue created Feb 02, 2018 by Mark OLESEN@markMaintainer

misleading name for two-parameter Foam::name()

  • currently accepts a printf-style format string. It should probably be renamed as format instead. Since this is reasonably infrequently used, I think that it should be relegated to the stringOps namespace as well. Eg,

    stringOps::format("fmt%d", 10);

In fact, probably want to make the whole thing templated:

template<class Primitive, class StringType=string>
StringType format(const char* fmt, const Primitive& val)

If desired, could have convenience static word::format as part of the word class, etc.

Might also consider with Args... forwarding.

Edited Feb 02, 2018 by Mark OLESEN
Assignee
Assign to
Time tracking