Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Boolean/operator/condition extensions? :> #4

Open
PuppyPi opened this issue May 23, 2021 · 0 comments
Open

Boolean/operator/condition extensions? :> #4

PuppyPi opened this issue May 23, 2021 · 0 comments

Comments

@PuppyPi
Copy link
Owner

PuppyPi commented May 23, 2021

Here's my ideas:

• Short-circuiting boolean operators! :D
• Should the syntax be like "AND!" and "OR!" or something else? :3

• NOT and XOR! :D

• Function/expression versions so prefix notation (aka "Polish notation" for some reason XD ) can be used instead of adding parentheses to CAOS which massively complicates the parsing XD''
Eg,
a AND NOT (b OR c) → AND# a NOT OR# b c
a AND (NOT b) OR c → AND# a OR# NOT b c
a AND (b = c) → AND# a EQ# b c
(a AND b) = c → EQ# AND# a b c
See #3 for discussion of the syntax for that :3
(But then what of both short-circuiting and function syntax!? AND#! or AND!# or etc.? XD )

• Bitwise (integer) and boolean overload sometimes like integer and float do :3
(so AND# can be used in place of both ANDV (integers) and AND (conditions) with no concerns about making two of them :> )
(we could definitely have two versions though! it'd be easier on the engine/compiler of course; the only reason to do it is for syntax/elegance for the caos writers :3 )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant