This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of TS status.

2650. [filesys.ts] [PDTS] path::compare(const string& s) wrong argument type

Section: 8 [filesys.ts::class.path] Status: TS Submitter: Stephan T. Lavavej Opened: 2014-02-03 Last modified: 2017-07-30

Priority: Not Prioritized

View all other issues in [filesys.ts::class.path].

View all issues with TS status.


Addresses: filesys.ts

path has "int compare(const string& s) const;" but it should almost certainly take const string_type&, since the third overload takes const value_type*.

[2014-02-08 Daniel comments and provides wording]

This issue is the same as 2643 and resolves that issue as well.

[2014-02-13 LWG/SG-3 Issaquah: Proposed wording accepted.]

Proposed resolution:

This wording is relative to SG3 working draft.

  1. Change class path synopsis, 8 [class.path], as indicated:

    // compare
    int compare(const path& p) const noexcept;
    int compare(const string_type& s) const;
    int compare(const value_type* s) const;
  2. Change path compare prototype specification, 8.4.8 [], as indicated:

    int compare(const string_type& s) const;