Skip to main content
GameDev.net gamedev.net
🔒 Locked

opImplConv not respected by shift operators

Started by Violet CLM Oct 24, 2021 at 4:27 PM 3 replies 5.6k views
Original Post
Violet CLM
Violet CLM

Given the following class:

class foo {
uint opImplConv() const { return 0; }
}

Any shift operator fails with an “illegal operation” error when the class is on the left side of the operator. foo >> 1, foo << 1, foo >>> 1 all fail but every other operator I've tried works fine.

WitchLord
WitchLord

Thanks for letting me know. I'll look into this.

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - <a href="http://www.angelcode.com/tower" rel
WitchLord
WitchLord

It took me a little over 4 years, but I've finally fixed this issue.

https://github.com/anjo76/angelscript/commit/752141b358f5e704b164e7816fdfca617bef1efe

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - <a href="http://www.angelcode.com/tower" rel
Violet CLM
Violet CLM

Very cool, thanks for tracking that down!

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.