Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix missing virtual declarations in Stream.h #10348

Merged

Conversation

TD-er
Copy link
Contributor

@TD-er TD-er commented Sep 14, 2024

Description of Change

Fixes some changes made in PR #10328

  • Virtual destructor was removed
  • Some functions had virtual removed

These changes do cause issues when operating on a Stream pointer instead of the derived class.

Copy link
Contributor

github-actions bot commented Sep 14, 2024

Warnings
⚠️

Some issues found for the commit messages in this PR:

  • the commit message "Fix missing virtual declarations in Stream.h":
    • summary looks empty
    • type/action looks empty
  • the commit message "Remove the virtual destructor as Print class has one":
    • summary looks empty
    • type/action looks empty

Please fix these commit messages - here are some basic tips:

  • follow Conventional Commits style
  • correct format of commit message should be: <type/action>(<scope/component>): <summary>, for example fix(esp32): Fixed startup timeout issue
  • allowed types are: change,ci,docs,feat,fix,refactor,remove,revert,test
  • sufficiently descriptive message summary should be between 20 to 72 characters and start with upper case letter
  • avoid Jira references in commit messages (unavailable/irrelevant for our customers)

TIP: Install pre-commit hooks and run this check when committing (uses the Conventional Precommit Linter).

👋 Hello TD-er, we appreciate your contribution to this project!


Click to see more instructions ...


This automated output is generated by the PR linter DangerJS, which checks if your Pull Request meets the project's requirements and helps you fix potential issues.

DangerJS is triggered with each push event to a Pull Request and modify the contents of this comment.

Please consider the following:
- Danger mainly focuses on the PR structure and formatting and can't understand the meaning behind your code or changes.
- Danger is not a substitute for human code reviews; it's still important to request a code review from your colleagues.
- Resolve all warnings (⚠️ ) before requesting a review from human reviewers - they will appreciate it.
- To manually retry these Danger checks, please navigate to the Actions tab and re-run last Danger workflow.

Review and merge process you can expect ...


We do welcome contributions in the form of bug reports, feature requests and pull requests.

1. An internal issue has been created for the PR, we assign it to the relevant engineer.
2. They review the PR and either approve it or ask you for changes or clarifications.
3. Once the GitHub PR is approved we do the final review, collect approvals from core owners and make sure all the automated tests are passing.
- At this point we may do some adjustments to the proposed change, or extend it by adding tests or documentation.
4. If the change is approved and passes the tests it is merged into the default branch.

Generated by 🚫 dangerJS against 7018619

Copy link
Contributor

github-actions bot commented Sep 14, 2024

Test Results

 56 files   -  83   56 suites   - 83   4m 45s ⏱️ - 1h 37m 11s
 21 tests  -   9   21 ✅  -   9  0 💤 ±0  0 ❌ ±0 
135 runs   - 168  135 ✅  - 168  0 💤 ±0  0 ❌ ±0 

Results for commit 7018619. ± Comparison against base commit 9e60bbe.

This pull request removes 9 tests.
performance.coremark.test_coremark ‑ test_coremark
performance.fibonacci.test_fibonacci ‑ test_fibonacci
performance.psramspeed.test_psramspeed ‑ test_psramspeed
performance.ramspeed.test_ramspeed ‑ test_ramspeed
performance.superpi.test_superpi ‑ test_superpi
test_touch_errors
test_touch_interrtupt
test_touch_read
validation.periman.test_periman ‑ test_periman

♻️ This comment has been updated with latest results.

@JAndrassy
Copy link
Contributor

JAndrassy commented Sep 14, 2024

the virtual destructor should be in the Print class

@TD-er
Copy link
Contributor Author

TD-er commented Sep 14, 2024

the virtual destructor should be in the Print class

OK, but the virtual declaration of the other functions should be there.

N.B. the Print class does have a virtual destructor, so I agree it is not needed in the Stream class.

Copy link
Contributor

Memory usage test (comparing PR against master branch)

The table below shows the summary of memory usage change (decrease - increase) in bytes and percentage for each target.

MemoryFLASH [bytes]FLASH [%]RAM [bytes]RAM [%]
TargetDECINCDECINCDECINCDECINC
ESP32S30‼️ +3K0.00‼️ +1.110⚠️ +160.00⚠️ +0.09
ESP32S20‼️ +3K0.00‼️ +1.220⚠️ +160.00⚠️ +0.12
ESP32C30⚠️ +11020.00⚠️ +0.420⚠️ +160.00⚠️ +0.14
ESP32C60⚠️ +11020.00⚠️ +0.510⚠️ +160.00⚠️ +0.13
ESP32H20⚠️ +11080.00⚠️ +0.420⚠️ +160.00⚠️ +0.13
ESP320‼️ +3K0.00‼️ +1.080⚠️ +160.00⚠️ +0.08
Click to expand the detailed deltas report [usage change in BYTES]
TargetESP32S3ESP32S2ESP32C3ESP32C6ESP32H2ESP32
ExampleFLASHRAMFLASHRAMFLASHRAMFLASHRAMFLASHRAMFLASHRAM
ArduinoOTA/examples/BasicOTA⚠️ +4400⚠️ +4720⚠️ +2880⚠️ +2800--⚠️ +4360
AsyncUDP/examples/AsyncUDPClient⚠️ +5440⚠️ +5360⚠️ +4140⚠️ +4140--⚠️ +5440
AsyncUDP/examples/AsyncUDPMulticastServer⚠️ +5600⚠️ +5360⚠️ +4140⚠️ +4140--⚠️ +5160
AsyncUDP/examples/AsyncUDPServer⚠️ +5600⚠️ +5440⚠️ +4140⚠️ +4140--⚠️ +5800
BLE/examples/BLE5_extended_scan⚠️ +7040--⚠️ +2140⚠️ +2060⚠️ +2140--
BLE/examples/BLE5_multi_advertising⚠️ +6760--⚠️ +2120⚠️ +2200⚠️ +2120--
BLE/examples/BLE5_periodic_advertising⚠️ +6720--⚠️ +2120⚠️ +2200⚠️ +2120--
BLE/examples/BLE5_periodic_sync⚠️ +6600--⚠️ +2200⚠️ +2120⚠️ +2200--
BLE/examples/Beacon_Scanner⚠️ +6920--⚠️ +2140⚠️ +2220⚠️ +2220⚠️ +7320
BLE/examples/Client⚠️ +6760--⚠️ +2060⚠️ +2140⚠️ +2140⚠️ +7160
BLE/examples/EddystoneTLM_Beacon⚠️ +6800--⚠️ +2140⚠️ +2060--⚠️ +7160
BLE/examples/EddystoneURL_Beacon⚠️ +7080--⚠️ +2140⚠️ +2220--⚠️ +7160
BLE/examples/Notify⚠️ +6920--⚠️ +2140⚠️ +2220⚠️ +2140⚠️ +6960
BLE/examples/Scan⚠️ +6680--⚠️ +2220⚠️ +2140⚠️ +2140⚠️ +7120
BLE/examples/Server⚠️ +7040--⚠️ +2120⚠️ +2200⚠️ +2120⚠️ +7120
BLE/examples/Server_multiconnect⚠️ +6960--⚠️ +2060⚠️ +2140⚠️ +2060⚠️ +7160
BLE/examples/UART⚠️ +6880--⚠️ +2140⚠️ +2220⚠️ +2140⚠️ +7200
BLE/examples/Write⚠️ +6920--⚠️ +2100⚠️ +2180⚠️ +2100⚠️ +7200
BLE/examples/iBeacon⚠️ +6840--⚠️ +2140⚠️ +2220⚠️ +2140⚠️ +7160
DNSServer/examples/CaptivePortal⚠️ +4480⚠️ +4520⚠️ +2320⚠️ +2320--⚠️ +4640
EEPROM/examples/eeprom_class⚠️ +3760⚠️ +3760⚠️ +3360⚠️ +3400⚠️ +3400⚠️ +3880
EEPROM/examples/eeprom_extra⚠️ +3640⚠️ +3640⚠️ +3420⚠️ +3360⚠️ +3380⚠️ +3760
EEPROM/examples/eeprom_write⚠️ +7960⚠️ +7960⚠️ +3400⚠️ +3400⚠️ +3400⚠️ +8080
ESP32/examples/AnalogOut/LEDCFade‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1004⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/AnalogOut/LEDCSingleChannel‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1010⚠️ +16⚠️ +1010⚠️ +16⚠️ +1018⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/AnalogOut/LEDCSoftwareFade‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1010⚠️ +16⚠️ +1010⚠️ +16⚠️ +1018⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/AnalogOut/SigmaDelta‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +998⚠️ +16⚠️ +1000⚠️ +16⚠️ +1006⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/AnalogOut/ledcFrequency‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1022⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/AnalogOut/ledcWrite_RGB‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1008⚠️ +16⚠️ +1012⚠️ +16⚠️ +1010⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/AnalogRead‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1018⚠️ +16⚠️ +1010⚠️ +16⚠️ +1018⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/AnalogReadContinuous‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1002⚠️ +16⚠️ +996⚠️ +16⚠️ +1004⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/ArduinoStackSize‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +990⚠️ +16⚠️ +990⚠️ +16⚠️ +992⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/CI/CIBoardsTest‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1088⚠️ +16⚠️ +1082⚠️ +16⚠️ +1090⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Camera/CameraWebServer⚠️ +4360⚠️ +4600------⚠️ +4480
ESP32/examples/ChipID/GetChipID⚠️ +3760⚠️ +3680⚠️ +3440⚠️ +3440⚠️ +3420⚠️ +3880
ESP32/examples/DeepSleep/ExternalWakeUp⚠️ +6920⚠️ +6840------⚠️ +7120
ESP32/examples/DeepSleep/TimerWakeUp⚠️ +6920⚠️ +6840⚠️ +2060⚠️ +2080--⚠️ +7120
ESP32/examples/DeepSleep/TouchWakeUp⚠️ +6920⚠️ +6920------⚠️ +6960
ESP32/examples/FreeRTOS/BasicMultiThreading‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1010⚠️ +16⚠️ +1004⚠️ +16⚠️ +1014⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/FreeRTOS/Mutex‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1008⚠️ +16⚠️ +1008⚠️ +16⚠️ +1012⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/FreeRTOS/Queue‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +998⚠️ +16⚠️ +998⚠️ +16⚠️ +1002⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/FreeRTOS/Semaphore‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +996⚠️ +16⚠️ +996⚠️ +16⚠️ +998⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/GPIO/BlinkRGB‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1008⚠️ +16⚠️ +998⚠️ +16⚠️ +1008⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/GPIO/FunctionalInterrupt‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1010⚠️ +16⚠️ +1000⚠️ +16⚠️ +1008⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/GPIO/FunctionalInterruptStruct‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1010⚠️ +16⚠️ +1012⚠️ +16⚠️ +1010⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/GPIO/GPIOInterrupt‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1006⚠️ +16⚠️ +1002⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/HWCDC_Events‼️ +2K⚠️ +16--⚠️ +1082⚠️ +16⚠️ +1078⚠️ +16⚠️ +1080⚠️ +16--
ESP32/examples/MacAddress/GetMacAddress⚠️ +7840⚠️ +7760⚠️ +3460⚠️ +3480⚠️ +3460⚠️ +7960
ESP32/examples/RMT/Legacy_RMT_Driver_Compatible⚠️ +6920⚠️ +6840⚠️ +2100⚠️ +2080⚠️ +2080⚠️ +7120
ESP32/examples/RMT/RMTCallback‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +996⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMTLoopback‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +996⚠️ +16⚠️ +996⚠️ +16⚠️ +996⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMTReadXJT‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1004⚠️ +16⚠️ +1004⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMTWrite_RGB_LED‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +990⚠️ +16⚠️ +990⚠️ +16⚠️ +990⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMT_CPUFreq_Test‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +998⚠️ +16⚠️ +998⚠️ +16⚠️ +998⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMT_EndOfTransmissionState‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/RMT/RMT_LED_Blink‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +998⚠️ +16⚠️ +1002⚠️ +16⚠️ +1004⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/ResetReason/ResetReason‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +998⚠️ +16⚠️ +1000⚠️ +16⚠️ +1000⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/ResetReason/ResetReason2‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1002⚠️ +16⚠️ +1002⚠️ +16⚠️ +1002⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/BaudRateDetect_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1006⚠️ +16⚠️ +1010⚠️ +16⚠️ +1010⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/OnReceiveError_BREAK_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1002⚠️ +16⚠️ +1002⚠️ +16⚠️ +1008⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/OnReceive_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1004⚠️ +16⚠️ +1004⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/RS485_Echo_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/RxFIFOFull_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1008⚠️ +16⚠️ +1008⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/RxTimeout_Demo‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1000⚠️ +16⚠️ +998⚠️ +16⚠️ +1000⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/Serial_All_CPU_Freqs‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1004⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/Serial_STD_Func_OnReceive‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +998⚠️ +16⚠️ +998⚠️ +16⚠️ +996⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Serial/onReceiveExample⚠️ +6680⚠️ +6680⚠️ +1840⚠️ +1860⚠️ +1860⚠️ +6760
ESP32/examples/TWAI/TWAIreceive‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1008⚠️ +16⚠️ +1006⚠️ +16⚠️ +1006⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/TWAI/TWAItransmit‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1018⚠️ +16⚠️ +1016⚠️ +16⚠️ +1016⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Template/ExampleTemplate‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1022⚠️ +16⚠️ +1016⚠️ +16⚠️ +1026⚠️ +16‼️ +3K⚠️ +16
ESP32/examples/Time/SimpleTime⚠️ +4440⚠️ +4640⚠️ +3300⚠️ +3300--⚠️ +4680
ESP32/examples/Timer/RepeatTimer‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1006⚠️ +16⚠️ +1010⚠️ +16⚠️ +1010⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Timer/WatchdogTimer‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1008⚠️ +16⚠️ +1010⚠️ +16⚠️ +1010⚠️ +16‼️ +2K⚠️ +16
ESP32/examples/Touch/TouchButtonV2‼️ +2K⚠️ +16‼️ +2K⚠️ +16--------
ESP32/examples/Touch/TouchInterrupt‼️ +2K⚠️ +16‼️ +2K⚠️ +16------‼️ +2K⚠️ +16
ESP32/examples/Touch/TouchRead‼️ +2K⚠️ +16‼️ +2K⚠️ +16------‼️ +2K⚠️ +16
ESP32/examples/Utilities/HEXBuilder⚠️ +7840⚠️ +7840⚠️ +3320⚠️ +3320⚠️ +3280⚠️ +7960
ESP32/examples/Utilities/MD5Builder⚠️ +2840⚠️ +2800⚠️ +2220⚠️ +2220⚠️ +2220⚠️ +2720
ESP32/examples/Utilities/SHA1Builder⚠️ +2840⚠️ +2880⚠️ +2180⚠️ +2180⚠️ +2180⚠️ +2720
ESP_I2S/examples/ES8388_loopback‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1102⚠️ +16⚠️ +1102⚠️ +16⚠️ +1108⚠️ +16‼️ +2K⚠️ +16
ESP_I2S/examples/Record_to_WAV⚠️ +8560--------⚠️ +8800
ESP_I2S/examples/Simple_tone‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1016⚠️ +16⚠️ +1026⚠️ +16⚠️ +1026⚠️ +16‼️ +2K⚠️ +16
ESP_NOW/examples/ESP_NOW_Broadcast_Master⚠️ +3840⚠️ +3720⚠️ +2020⚠️ +2120--⚠️ +3840
ESP_NOW/examples/ESP_NOW_Broadcast_Slave⚠️ +3840⚠️ +3800⚠️ +2040⚠️ +2100--⚠️ +4040
ESP_NOW/examples/ESP_NOW_Network⚠️ +3800⚠️ +3840⚠️ +2100⚠️ +2180--⚠️ +3880
ESP_NOW/examples/ESP_NOW_Serial⚠️ +5800⚠️ +5520⚠️ +4220⚠️ +4300--⚠️ +5600
ESP_SR/examples/Basic⚠️ +4320----------
ESPmDNS/examples/mDNS-SD_Extended⚠️ +4320⚠️ +4560⚠️ +3380⚠️ +3480--⚠️ +4680
ESPmDNS/examples/mDNS_Web_Server⚠️ +3960⚠️ +3920⚠️ +2700⚠️ +2700--⚠️ +4120
Ethernet/examples/ETH_W5500_Arduino_SPI⚠️ +5480⚠️ +5640⚠️ +4660⚠️ +4660⚠️ +4660⚠️ +5720
Ethernet/examples/ETH_W5500_IDF_SPI⚠️ +5480⚠️ +5480⚠️ +4660⚠️ +4660⚠️ +4660⚠️ +5720
Ethernet/examples/ETH_WIFI_BRIDGE⚠️ +4680⚠️ +4360⚠️ +3380⚠️ +3300--⚠️ +4480
FFat/examples/FFat_Test⚠️ +7760⚠️ +7840⚠️ +2400⚠️ +2400⚠️ +2320⚠️ +7960
FFat/examples/FFat_time⚠️ +4920⚠️ +4920⚠️ +2820⚠️ +2820--⚠️ +5200
HTTPClient/examples/Authorization⚠️ +4400⚠️ +4320⚠️ +2560⚠️ +2560--⚠️ +4440
HTTPClient/examples/BasicHttpClient⚠️ +4400⚠️ +4400⚠️ +2640⚠️ +2640--⚠️ +4440
HTTPClient/examples/BasicHttpsClient⚠️ +4200⚠️ +4480⚠️ +2560⚠️ +2560--⚠️ +4480
HTTPClient/examples/HTTPClientEnterprise⚠️ +4640⚠️ +4880⚠️ +2700⚠️ +2700--⚠️ +4960
HTTPClient/examples/ReuseConnection⚠️ +4320⚠️ +4400⚠️ +2560⚠️ +2560--⚠️ +4480
HTTPClient/examples/StreamHttpClient⚠️ +4160⚠️ +4440⚠️ +2660⚠️ +2660--⚠️ +4440
HTTPUpdate/examples/httpUpdate⚠️ +4640⚠️ +4840⚠️ +3040⚠️ +3040--⚠️ +4840
HTTPUpdate/examples/httpUpdateSPIFFS⚠️ +4560⚠️ +4600⚠️ +3040⚠️ +3040--⚠️ +4600
HTTPUpdate/examples/httpUpdateSecure⚠️ +4600⚠️ +4960⚠️ +3200⚠️ +3260--⚠️ +5040
HTTPUpdateServer/examples/WebUpdater⚠️ +4680⚠️ +4720⚠️ +2480⚠️ +2560--⚠️ +4760
Insights/examples/DiagnosticsSmokeTest⚠️ +4560⚠️ +4560⚠️ +3300----⚠️ +4760
Insights/examples/MinimalDiagnostics⚠️ +4640⚠️ +4600⚠️ +3380----⚠️ +4640
LittleFS/examples/LITTLEFS_test⚠️ +7920⚠️ +7840⚠️ +2440⚠️ +2440⚠️ +2340⚠️ +8120
LittleFS/examples/LITTLEFS_time⚠️ +4720⚠️ +4920⚠️ +2820⚠️ +2820--⚠️ +4840
NetBIOS/examples/ESP_NBNST⚠️ +5640⚠️ +5360⚠️ +4220⚠️ +4140--⚠️ +5320
NetworkClientSecure/examples/WiFiClientInsecure⚠️ +5160⚠️ +5320⚠️ +3860⚠️ +3780--⚠️ +5320
NetworkClientSecure/examples/WiFiClientPSK⚠️ +5000⚠️ +5280⚠️ +3860⚠️ +3780--⚠️ +5320
NetworkClientSecure/examples/WiFiClientSecure⚠️ +4880⚠️ +5240⚠️ +3780⚠️ +3700--⚠️ +5160
NetworkClientSecure/examples/WiFiClientSecureEnterprise⚠️ +5560⚠️ +5840⚠️ +3840⚠️ +3920--⚠️ +5800
NetworkClientSecure/examples/WiFiClientSecureProtocolUpgrade⚠️ +5280⚠️ +5400⚠️ +3780⚠️ +3860--⚠️ +5280
NetworkClientSecure/examples/WiFiClientShowPeerCredentials⚠️ +4960⚠️ +5200⚠️ +3800⚠️ +3800--⚠️ +5160
NetworkClientSecure/examples/WiFiClientTrustOnFirstUse⚠️ +5120⚠️ +5240⚠️ +3760⚠️ +3840--⚠️ +5360
PPP/examples/PPP_Basic⚠️ +5480⚠️ +5560⚠️ +4780⚠️ +4780⚠️ +4700⚠️ +5640
PPP/examples/PPP_WIFI_BRIDGE⚠️ +4640⚠️ +4360⚠️ +3380⚠️ +3380--⚠️ +4600
Preferences/examples/Prefs2Struct⚠️ +7960⚠️ +7880⚠️ +3400⚠️ +3400⚠️ +3380⚠️ +8080
Preferences/examples/StartCounter⚠️ +3760⚠️ +3880⚠️ +3500⚠️ +3500⚠️ +3480⚠️ +3880
RainMaker/examples/RMakerCustom⚠️ +4680⚠️ +4600⚠️ +3360⚠️ +3360--⚠️ +5520
RainMaker/examples/RMakerCustomAirCooler⚠️ +4520⚠️ +4640⚠️ +3460⚠️ +3460--⚠️ +4680
RainMaker/examples/RMakerSonoffDualR3⚠️ +4560⚠️ +4640⚠️ +3440⚠️ +3440--⚠️ +4760
RainMaker/examples/RMakerSwitch⚠️ +4720⚠️ +4480⚠️ +3420⚠️ +3420--⚠️ +5440
SD/examples/SD_Test⚠️ +7760⚠️ +7840⚠️ +2380⚠️ +2400⚠️ +2320⚠️ +8120
SD/examples/SD_time⚠️ +4880⚠️ +4680⚠️ +2780⚠️ +2780--⚠️ +5240
SD_MMC/examples/SD2USBMSC⚠️ +8280----------
SD_MMC/examples/SDMMC_Test⚠️ +7760--------⚠️ +8120
SD_MMC/examples/SDMMC_time⚠️ +4960--------⚠️ +5040
SPI/examples/SPI_Multiple_Buses‼️ +3K⚠️ +16‼️ +3K⚠️ +16------‼️ +3K⚠️ +16
SPIFFS/examples/SPIFFS_Test⚠️ +7760⚠️ +7840⚠️ +2300⚠️ +2300⚠️ +2300⚠️ +8120
SPIFFS/examples/SPIFFS_time⚠️ +4720⚠️ +4920⚠️ +2780⚠️ +2780--⚠️ +5040
SimpleBLE/examples/SimpleBleDevice⚠️ +2600----⚠️ +2040⚠️ +2040⚠️ +3000
TFLiteMicro/examples/hello_world‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1006⚠️ +16⚠️ +1004⚠️ +16⚠️ +1010⚠️ +16‼️ +3K⚠️ +16
Ticker/examples/Blinker‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1018⚠️ +16⚠️ +1000⚠️ +16⚠️ +1006⚠️ +16‼️ +3K⚠️ +16
Ticker/examples/TickerBasic‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1016⚠️ +16⚠️ +1000⚠️ +16⚠️ +1006⚠️ +16‼️ +3K⚠️ +16
Ticker/examples/TickerParameter‼️ +3K⚠️ +16‼️ +3K⚠️ +16⚠️ +1008⚠️ +16⚠️ +992⚠️ +16⚠️ +1000⚠️ +16‼️ +3K⚠️ +16
USB/examples/CompositeDevice⚠️ +8680⚠️ +8720--------
USB/examples/ConsumerControl⚠️ +8520⚠️ +8200--------
USB/examples/CustomHIDDevice⚠️ +8120⚠️ +8120--------
USB/examples/FirmwareMSC⚠️ +7800⚠️ +7640--------
USB/examples/Gamepad⚠️ +8120⚠️ +8120--------
USB/examples/HIDVendor⚠️ +8280⚠️ +8200--------
USB/examples/Keyboard/KeyboardLogout⚠️ +8360⚠️ +8240--------
USB/examples/Keyboard/KeyboardMessage⚠️ +8360⚠️ +8240--------
USB/examples/Keyboard/KeyboardReprogram⚠️ +8360⚠️ +8120--------
USB/examples/Keyboard/KeyboardSerial⚠️ +8120⚠️ +8120--------
USB/examples/KeyboardAndMouseControl⚠️ +8120⚠️ +8120--------
USB/examples/MIDI/MidiController⚠️ +8120⚠️ +8120--------
USB/examples/MIDI/MidiInterface⚠️ +8120⚠️ +8120--------
USB/examples/MIDI/MidiMusicBox⚠️ +8120⚠️ +8120--------
USB/examples/MIDI/ReceiveMidi⚠️ +8120⚠️ +8120--------
USB/examples/Mouse/ButtonMouseControl⚠️ +8520⚠️ +8120--------
USB/examples/SystemControl⚠️ +8360⚠️ +8200--------
USB/examples/USBMSC⚠️ +7640⚠️ +7720--------
USB/examples/USBSerial⚠️ +8040⚠️ +8080--------
USB/examples/USBVendor⚠️ +8280⚠️ +8280--------
Update/examples/AWS_S3_OTA_Update⚠️ +3440⚠️ +3600⚠️ +2080⚠️ +2160--⚠️ +3680
Update/examples/HTTPS_OTA_Update⚠️ +3520⚠️ +3760⚠️ +2380⚠️ +2380--⚠️ +3800
Update/examples/HTTP_Client_AES_OTA_Update⚠️ +4720⚠️ +4800⚠️ +3100⚠️ +3040--⚠️ +4920
Update/examples/HTTP_Server_AES_OTA_Update⚠️ +5080⚠️ +5200⚠️ +2640⚠️ +2740--⚠️ +5040
Update/examples/OTAWebUpdater⚠️ +4000⚠️ +4120⚠️ +1880⚠️ +1960--⚠️ +4160
Update/examples/SD_Update⚠️ +3280⚠️ +3240⚠️ +1640⚠️ +1720⚠️ +1720⚠️ +3400
WebServer/examples/AdvancedWebServer⚠️ +3760⚠️ +3680⚠️ +1580⚠️ +1660--⚠️ +3600
WebServer/examples/FSBrowser⚠️ +4040⚠️ +4200⚠️ +1620⚠️ +1700--⚠️ +4120
WebServer/examples/Filters⚠️ +3600⚠️ +3600⚠️ +1660⚠️ +1580--⚠️ +3680
WebServer/examples/HelloServer⚠️ +3560⚠️ +3640⚠️ +1660⚠️ +1580--⚠️ +3720
WebServer/examples/HttpAdvancedAuth⚠️ +4040⚠️ +4160⚠️ +1700⚠️ +1780--⚠️ +3960
WebServer/examples/HttpAuthCallback⚠️ +3800⚠️ +4080⚠️ +1880⚠️ +1800--⚠️ +4000
WebServer/examples/HttpAuthCallbackInline⚠️ +3880⚠️ +4280⚠️ +1880⚠️ +1780--⚠️ +4000
WebServer/examples/HttpBasicAuth⚠️ +4000⚠️ +4080⚠️ +1860⚠️ +1780--⚠️ +3920
WebServer/examples/HttpBasicAuthSHA1⚠️ +4040⚠️ +3960⚠️ +1820⚠️ +1740--⚠️ +3960
WebServer/examples/HttpBasicAuthSHA1orBearerToken⚠️ +3840⚠️ +4000⚠️ +1840⚠️ +1760--⚠️ +4000
WebServer/examples/MultiHomedServers⚠️ +3680⚠️ +3560⚠️ +1660⚠️ +1580--⚠️ +3720
WebServer/examples/PathArgServer⚠️ +3760⚠️ +3680⚠️ +1500⚠️ +1500--⚠️ +3800
WebServer/examples/SDWebServer⚠️ +4000⚠️ +4280⚠️ +1780⚠️ +1700--⚠️ +4080
WebServer/examples/SimpleAuthentification⚠️ +3600⚠️ +3600⚠️ +1580⚠️ +1660--⚠️ +3600
WebServer/examples/UploadHugeFile⚠️ +4360⚠️ +4720⚠️ +2460⚠️ +2300--⚠️ +4280
WebServer/examples/WebServer⚠️ +4760⚠️ +4760⚠️ +2580⚠️ +2580--⚠️ +4720
WebServer/examples/WebUpdate⚠️ +3280⚠️ +3240⚠️ +1040⚠️ +960--⚠️ +3240
WiFi/examples/FTM/FTM_Initiator⚠️ +4560⚠️ +4160⚠️ +3380⚠️ +3460--⚠️ +4760
WiFi/examples/FTM/FTM_Responder⚠️ +4360⚠️ +4440⚠️ +3320⚠️ +3440--⚠️ +4680
WiFi/examples/SimpleWiFiServer⚠️ +4240⚠️ +4320⚠️ +3120⚠️ +3200--⚠️ +4440
WiFi/examples/WPS⚠️ +3440⚠️ +3480⚠️ +2100⚠️ +2020--⚠️ +3880
WiFi/examples/WiFiAccessPoint⚠️ +4240⚠️ +4440⚠️ +3120⚠️ +3200--⚠️ +4640
WiFi/examples/WiFiBlueToothSwitch⚠️ +4360--⚠️ +3480⚠️ +3380--⚠️ +4720
WiFi/examples/WiFiClient⚠️ +3920⚠️ +3880⚠️ +2680⚠️ +2660--⚠️ +4160
WiFi/examples/WiFiClientBasic⚠️ +3920⚠️ +3920⚠️ +2680⚠️ +2660--⚠️ +4480
WiFi/examples/WiFiClientConnect⚠️ +4440⚠️ +4640⚠️ +3300⚠️ +3380--⚠️ +4520
WiFi/examples/WiFiClientEnterprise⚠️ +3920⚠️ +3960⚠️ +2660⚠️ +2660--⚠️ +3960
WiFi/examples/WiFiClientEvents⚠️ +4360⚠️ +4600⚠️ +3300⚠️ +3400--⚠️ +4520
WiFi/examples/WiFiClientStaticIP⚠️ +3920⚠️ +3880⚠️ +2680⚠️ +2680--⚠️ +4240
WiFi/examples/WiFiExtender⚠️ +4640⚠️ +4720⚠️ +3460⚠️ +3400--⚠️ +4680
WiFi/examples/WiFiIPv6⚠️ +5080⚠️ +5280⚠️ +4240⚠️ +4160--⚠️ +5280
WiFi/examples/WiFiMulti⚠️ +4720⚠️ +4400⚠️ +3380⚠️ +3300--⚠️ +4480
WiFi/examples/WiFiMultiAdvanced⚠️ +5000⚠️ +5240⚠️ +3780⚠️ +3780--⚠️ +5520
WiFi/examples/WiFiScan⚠️ +4560⚠️ +4360⚠️ +3380⚠️ +3300--⚠️ +4800
WiFi/examples/WiFiScanAsync⚠️ +4480⚠️ +4320⚠️ +3400⚠️ +3300--⚠️ +4840
WiFi/examples/WiFiScanDualAntenna⚠️ +4600⚠️ +4400⚠️ +3380⚠️ +3480--⚠️ +4680
WiFi/examples/WiFiScanTime⚠️ +4280⚠️ +4320⚠️ +3480⚠️ +3380--⚠️ +4680
WiFi/examples/WiFiSmartConfig⚠️ +4400⚠️ +4480⚠️ +3320⚠️ +3380--⚠️ +4560
WiFi/examples/WiFiTelnetToSerial⚠️ +5480⚠️ +5400⚠️ +4620⚠️ +4700--⚠️ +5560
WiFi/examples/WiFiUDPClient⚠️ +4080⚠️ +4200⚠️ +2980⚠️ +2920--⚠️ +4480
WiFiProv/examples/WiFiProv⚠️ +4040⚠️ +4560⚠️ +3380⚠️ +3380--⚠️ +4680
Wire/examples/WireMaster⚠️ +3840⚠️ +3960⚠️ +3040⚠️ +3000⚠️ +3000⚠️ +4000
Wire/examples/WireScan‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1082⚠️ +16⚠️ +1078⚠️ +16⚠️ +1076⚠️ +16‼️ +2K⚠️ +16
Wire/examples/WireSlave‼️ +2K⚠️ +16‼️ +2K⚠️ +16⚠️ +1086⚠️ +16⚠️ +1076⚠️ +16⚠️ +1074⚠️ +16‼️ +2K⚠️ +16
OpenThread/examples/COAP/coap_lamp------⚠️ +2220⚠️ +2240--
OpenThread/examples/COAP/coap_switch------⚠️ +2140⚠️ +2140--
OpenThread/examples/SimpleCLI------⚠️ +2560⚠️ +2660--
OpenThread/examples/SimpleNode------⚠️ +2400⚠️ +2460--
OpenThread/examples/SimpleThreadNetwork/ExtendedRouterNode------⚠️ +2400⚠️ +2440--
OpenThread/examples/SimpleThreadNetwork/LeaderNode------⚠️ +2580⚠️ +2680--
OpenThread/examples/SimpleThreadNetwork/RouterNode------⚠️ +2600⚠️ +2660--
OpenThread/examples/ThreadScan------⚠️ +2140⚠️ +2220--
OpenThread/examples/onReceive------⚠️ +2660⚠️ +2660--
BluetoothSerial/examples/DiscoverConnect----------⚠️ +4800
BluetoothSerial/examples/GetLocalMAC----------⚠️ +4640
BluetoothSerial/examples/SerialToSerialBT----------⚠️ +4880
BluetoothSerial/examples/SerialToSerialBTM----------⚠️ +4880
BluetoothSerial/examples/SerialToSerialBT_Legacy----------⚠️ +4280
BluetoothSerial/examples/SerialToSerialBT_SSP----------⚠️ +4440
BluetoothSerial/examples/bt_classic_device_discovery----------⚠️ +5040
BluetoothSerial/examples/bt_remove_paired_devices----------⚠️ +4720
ESP32/examples/DeepSleep/SmoothBlink_ULP_Code----------‼️ +2K⚠️ +16
ESP32/examples/Touch/TouchButton----------‼️ +2K⚠️ +16
Ethernet/examples/ETH_LAN8720----------⚠️ +5800
Ethernet/examples/ETH_TLK110----------⚠️ +5800

@me-no-dev
Copy link
Member

@TD-er have you thought of proposing this upstream?

@P-R-O-C-H-Y P-R-O-C-H-Y added the Status: Pending Merge Pull Request is ready to be merged label Sep 16, 2024
@TD-er
Copy link
Contributor Author

TD-er commented Sep 16, 2024

@TD-er have you thought of proposing this upstream?

Nope, as I don't know why it was already different on this repo to begin with.

To me it makes perfect sense why those functions should be virtual, but I can't think of any reason why they are not made virtual in the upstream code.
Nor can I oversee what effect it may have on small microcontrollers as marking it virtual may add some to the build size and I guess Stream.h may be used in quite a lot of code.

@me-no-dev
Copy link
Member

it also adds up to 3K of flash here too. Should you maybe rethink your code and not overwrite those?

@TD-er
Copy link
Contributor Author

TD-er commented Sep 16, 2024

It does make both ESP32 and ESP8266 implementations different.
Also I don't know which other libraries may break because of this.

Not sure what will happen when calling these functions when you have a pointer to the Stream base class, I guess then the implementation of the derived class will not be called right?

@me-no-dev
Copy link
Member

You can give it a shot. I think the derived class will be called.

@TD-er
Copy link
Contributor Author

TD-er commented Sep 16, 2024

You can give it a shot. I think the derived class will be called.

Nope, it will not.
See: https://www.programiz.com/cpp-programming/virtual-functions

However, according to this, we could declare these functions with override in the Stream class? (see linked page roughly half way)
Then it isn't declared virtual.
This should reduce the bin file a bit, though I don't think it will be the same size as it is now.

N.B. I don't know if I understood this alternative option 100% correct, so if I didn't please point me to the correct documentation or links to the standard or some examples.

@JAndrassy
Copy link
Contributor

JAndrassy commented Sep 16, 2024

override specifier (since C++11) Specifies that a virtual function overrides another virtual function.

compiler will check if a virtual function with the specified name and parameters exists in the base class

@TD-er
Copy link
Contributor Author

TD-er commented Sep 16, 2024

override specifier (since C++11) Specifies that a virtual function overrides another virtual function.

compiler will check if a virtual function with the specified name and parameters exists in the base class

Yep, that's how I found this as the compiler complained.

However the question is if we could do without virtual here?
If not, then it is for sure also a bug in the upstream Arduino code.

@me-no-dev me-no-dev merged commit e989445 into espressif:master Sep 17, 2024
71 checks passed
@TD-er TD-er deleted the bugfix/revert_some_stream_class_changes branch September 17, 2024 09:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Pending Merge Pull Request is ready to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants