WerWolv / ImHex

🔍 A Hex Editor for Reverse Engineers, Programmers and people who value their retinas when working at 3 AM.
https://imhex.werwolv.net
GNU General Public License v2.0
43.96k stars 1.92k forks source link

[Bug] #pragma eval_depth is nonfunctional and seemingly ignored by the compiler #1716

Closed EtiTheSpirit closed 4 months ago

EtiTheSpirit commented 4 months ago

Operating System

Windows

What's the issue you encountered?

I am crossporting a piece of code from 010 editor, and when doing this, I ran into the evaluation depth limit. When prompted with the instructions of how to raise the limit, I did exactly as it suggested, only to see the exact same error appear with the same limit of 32 reported to me.

I tried a bunch of numbers, all of which made no change, until I ultimately decided I'd take a break and type in some random nonsense before I moved onto other work. It was in this moment I learned that indeed, #pragma eval_depth at least seven will compile. This also includes negative values, floating point values, nothing. It just works™. Good.

How can the issue be reproduced?

  1. Make a new file and open the pattern editor.
  2. Enter #pragma eval_depth asdfg and compile.
  3. This should compile without error. Anything after eval_depth (including nothing) will compile without complaint.

ImHex Version

1.33.2

ImHex Build Type

Installation type

MSI

Additional context?

No response

paxcut commented 4 months ago

The bug only exists on the release branch (1.33.2). Master branch (1.33.0) fixes it and any recent nightly build with version 1.33.0 should have working #pragma directives.