First steps, the compiler can boot with enforced requiresInit
This commit is contained in:
parent
216fd59c44
commit
a8b6222c86
7 changed files with 26 additions and 29 deletions
|
|
@ -75,16 +75,16 @@ varargso("foo", "bar", "baz")
|
|||
|
||||
type
|
||||
Flago = enum
|
||||
tfNeedsInit, tfNotNil
|
||||
tfRequiresInit, tfNotNil
|
||||
|
||||
var s: set[Flago] = {tfNeedsInit}
|
||||
var s: set[Flago] = {tfRequiresInit}
|
||||
|
||||
if {tfNeedsInit, tfNotNil} * s != {}:
|
||||
if {tfRequiresInit, tfNotNil} * s != {}:
|
||||
echo "yes"
|
||||
else:
|
||||
echo "no"
|
||||
|
||||
if {tfNeedsInit, tfNotNil} * s <= {tfNotNil}:
|
||||
if {tfRequiresInit, tfNotNil} * s <= {tfNotNil}:
|
||||
echo "yes"
|
||||
else:
|
||||
echo "no"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue