C++ Logo


Advanced search

Difference in default argument re.regex vs. re.regex.assign

From: Mark de Wever <koraq_at_[hidden]>
Date: Thu, 5 Sep 2019 21:49:39 +0200
I've been looking at the regex documentation in N4830 and see an

basic_regex& assign(const charT* p, size_t len, flag_type f);

basic_regex& assign(const charT* ptr, size_t len, flag_type f =

Is the difference in the default argument between to two places a
defect? I assume it is and I should file a DR. IMO it should be
defaulted to regex_constants::ECMAScript at both places. At least one
implementation (libc++) implements the assignment without a default

Is this a real defect? Should it be a DR or an editorial issue?

Kind regards,
Mark de Wever

PS: I consider the difference between p and ptr and an editorial issue
and will create a pull request at GitHub. There are some other editorial
issues here which will be added in the same pull request.

Received on 2019-09-05 14:51:49