8000 SoftwareSerial breaks abs macro · Issue #30 · arduino/ArduinoCore-avr · GitHub
[go: up one dir, main page]

Skip to content
SoftwareSerial breaks abs macro #30
Closed
@florian-schweiger

Description

@florian-schweiger

When I include SoftwareSerial.h, other libraries break because the abs(x) macro stops working. One particular library that stops functioning properly is uStepper.

The reason for it seems to be a section at the bottom of SoftwareSerial.h that undefines several macros:

// Arduino 0012 workaround
#undef int
#undef char
#undef long
#undef byte
#undef float
#undef abs
#undef round

I've commented this out in my project, and things are back to normal.

So I'm wondering, is this workaround still needed in the post-Arduino-0012 era?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0