&&& was accidentally available as a valid prefix operator.

This commit is contained in:
Christoffer Lerno
2025-05-21 23:36:33 +02:00
parent 3cd2267b0a
commit bd1de1e7dc
3 changed files with 17 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
import std;
fn int main()
{
// This works
int** my_super_cool_pointer = &&(&&1);
// This doesn't
int** my_super_cool_pointer2 = &&&&1; // #error: '&&&' is the compile time '&&' operator
return 0;
}