Skip to content

The preprocessor expression backend does not adhere to the VBA specification #3967

Open
@MDoerner

Description

@MDoerner

Currently the backend for expression evaluation in the preprossessor does not follow the rules layed out in the VBA specification (section 2.1 and 5.6.9). This has the potential effect that we do not determine correctly which code is dead and which is not.

Most of the computations have an incorrect return type and the computations are not performed with the specified precision. (The backend seems to always use decimal.)

Moreover, the handling of octal and hex literals does not take into considerations that the value depends on the type suffix provided, e.g. &o100000 = -32768, but &o100000& = 32768.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIdentifies work items for known bugsedge-caseMarks a bug as an edge case that would be nice to fix, but that likely doesn't affect normal use.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions