#else     # else without if
#elif     # elif without if
#elif!    # elif! without if
#if       # expected if-expression
#if test  # expected true or false
#if true  # expected {
#x
#if true   # expected newline after {
#{x
#if true   # expected newline after }
#{
#}x

if true
{
  print 1
}
else
{
  print 0
}

if! true
{
  print 0
}
else
{
  print 1
}

if false
{
  print 0
}
else
{
  print 1
}

if false
{
  print 0
}
elif true
{
  print 1
}
else
{
  print 0
}

if true
{
  print 1
}
elif true
{
  print 0
}
else
{
  print 0
}

# Empty block
#
if true
{
}
else
{
  print 0
}

# Nested if-else
#
if true
{
  if true
  {
    print 1
  }
}
else
{
  if true
  {
    print 0
  }
}

t = true
f = false

if $t
{
  print 1
}

if! $f
{
  print 1
}

# With eval context.
#
if (foo == foo)
{
  print 1
}

if(foo != bar)
{
  print 1
}

if!(foo == bar)
{
  print 1
}

if ([uint64] 01 == [uint64] 1)
{
  print 1
}

# Single line.
#

#if true
#}        # expected if-line

if true
  print 1

if false

  print 0
else
  # Comment.
  print 1

if true
  if false
    print 0
  else
    print 1

# Brace ambiguity.
#
if false
  {dir}{.}: x = 0
else
  {dir}{.}: x = 1

print $(dir{.}:x)

# EOF test.
#
./:

if true
{
  print 1
}