Skip to content

In-Game: Bitwise operations at compile-time return the incorrect type #10043

@tinkerer-red

Description

@tinkerer-red

Description

As a sister issue to #10029 it was noticed that compile time optimizations for bitwise operations result in inconsistent returns. It's expected that a bitwise operation should always return an int64, however at compile time this is converted into a number type. Generally this isn't much of an issue as we could simply int64() this, but when accounting for the test framework this will cause some unexpected results for such tests.
Image

The change made in the other issue will resolve this, but when using 2 numbers the returned result should still be an int64.
Image

Expected Change

Compile time results for all bitwise operations should type resolve as int64

Steps To Reproduce

Sample project:
https://api.gamemaker.io/api/github/downloads/30748c8b-405a-4627-a606-48065e5af500

How reliably can you recreate this issue using your steps above?

Always

Which version of GameMaker are you reporting this issue for?

2024.11.0 (Monthly)

Which platform(s) are you seeing the problem on?

Windows

Sample Package Attached?

  • I have attached my bug package

Sample Project Added?

  • I have included a small sample project

Metadata

Metadata

Labels

gms2-bugIn-game bugs with the "GameMaker Studio 2" runtimes
No fields configured for In-Game Bug.

Projects

Status

Verified

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions