NVIDIA / NVIDIA/cccl

`cuda::std::complex` Doesn't Work With `std::ostream`

Open
#961 0 comments 0 reactions 1 assignee Claimed by @wmaxey View on GitHub
libcu++
Dominant language
C++
Stars
2.5k
Forks
487
Avg merge
2d 7h
Merged PRs (30d)
296

Description

```
cuda::std::complex a{1,0};
std::cout << a;
```
Gives the error:
```
error: no operator "<<" matches these operands
operand types are: std::basic_ostream> << cuda::std::__3::complex
```

From @ogiroux:
```
It’s probably expecting a cuda::std::ostream which doesn’t exist. The host-only library and the host+device library are totally separate despite appearance of compatibility.
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.