Issue 120178
Summary `ios_base::sync_with_stdio` doesn't seem to do anything
Labels bug, libc++
Assignees
Reporter cjdb
    Here's the implementation for `ios_base::sync_with_stdio`:

```cpp
bool ios_base::sync_with_stdio(bool sync) {
  static bool previous_state = true;
  bool r                     = previous_state;
  previous_state = sync;
  return r;
}
```

As far as I can tell, that's only shuffling the state of a local bool, which tells me that it might not be decoupling iostream from stdio (I can't find any usage of the function to probe the state by the library, and since it's a local variable, it's not affecting anything on a broader level).
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to