 /**
  * ConstraintAttributes is an options set that maps to NSLayoutAttributes.
  */
-struct ConstraintAttributes: RawOptionSet {
+struct ConstraintAttributes: RawOptionSetType {
 
     var value: UInt
+    var boolValue: Bool {
+        return self.value != 0
+    }
 
     init(_ value: UInt) {
         self.value = value

        return attrs
    }
}
@assignment func += (inout left: ConstraintAttributes, right: ConstraintAttributes) {
    left = (left | right)
}
@assignment func -= (inout left: ConstraintAttributes, right: ConstraintAttributes) {
    left = ConstraintAttributes(left.toRaw() & ~right.toRaw())
}

/**

    private weak var installedOnView: View?
    
    private func addConstraint(attributes: ConstraintAttributes) -> Constraint {
        if self.relation == nil {
            self.fromItem.attributes += attributes
        }
        return self
