softprops / atty

are you or are you not a tty?
MIT License
271 stars 48 forks source link

Does not work correctly for wasm32-unknown-emscripten #21

Open icefoxen opened 6 years ago

icefoxen commented 6 years ago

The is() function gets defined twice, because you have one cfg statement that tests for OS (unix) and one that tests for architecture (wasm32). Emscripten pretends to be unix, so is() gets defined twice.

Proposed fix: turn the wasm32 architecture into an OS test for unknown.