microsoft / microsoft/STL

<functional>: Should binders be assignable?

Open
#199 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

LWG issue needed
Dominant language
C++
Stars
11.1k
Forks
1.7k
Avg merge
4d 15h
Merged PRs (30d)
22

Description

https://github.com/microsoft/STL/pull/158#issuecomment-544774999 said:

While writing tests, I observe that WG21-P1651 claims "functors produced by std::bind_front are not assignable". I can't find any Standardese requiring them to be assignable, but I also can't find any Standardese requiring assignment to be ill-formed. Your bind_front() object behaves the same as the bind() object, so I think this is fine as-is.

We should consider deleting the assignment operators for the bind_front() and bind() function objects.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the linked pull request comment and the requirements discussed for std::bind_front and std::bind. Inspect the corresponding function-object implementations and existing tests, then determine whether assignment should be ill-formed and what tests would establish the expected behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.