Skip to content

Commit e9dc626

Browse files
committed
[spec/version.dd] Tweak Static If section
1 parent 1ca5e4d commit e9dc626

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

spec/version.dd

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -545,23 +545,26 @@ class C
545545
$(CODE_HIGHLIGHT static if) (k == 5) // ok, k is in current scope
546546
int z;
547547
}
548-
549-
template INT(int i)
548+
---
549+
$(SPEC_RUNNABLE_EXAMPLE_FAIL
550+
---
551+
template Int(int i)
550552
{
551553
$(ARGS static if) (i == 32)
552-
alias INT = int;
554+
alias Int = int;
553555
$(ARGS else static if) (i == 16)
554-
alias INT = short;
556+
alias Int = short;
555557
$(ARGS else)
556558
static assert(0); // not supported
557559
}
558560

559-
INT!(32) a; // a is an int
560-
INT!(16) b; // b is a short
561-
INT!(17) c; // error, static assert trips
561+
Int!(32) a; // a is an int
562+
Int!(16) b; // b is a short
563+
Int!(17) c; // error, static assert trips
562564
------
565+
)
563566

564-
$(P A $(I StaticIfConditional) condition differs from an
567+
$(P A $(I StaticIfCondition) differs from an
565568
$(I IfStatement) in the following ways:
566569
)
567570

0 commit comments

Comments
 (0)