Skip to content

Commit 383798b

Browse files
author
Jenny Plunkett
committed
Revert "Remove note about Stream/Serial deprecation"
This reverts commit 5ee5b07.
1 parent b31bc76 commit 383798b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/Serial.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@ class Serial : public SerialBase, public Stream, private NonCopyable<Serial> {
8282
*/
8383
Serial(PinName tx, PinName rx, int baud);
8484

85+
/* Stream gives us a FileHandle with non-functional poll()/readable()/writable. Pass through
86+
* the calls from the SerialBase instead for backwards compatibility. This problem is
87+
* part of why Stream and Serial should be deprecated.
88+
*/
8589
bool readable()
8690
{
8791
return SerialBase::readable();

0 commit comments

Comments
 (0)