 		return failure(informativeUsageError(option))
 	}
 }
+
+/// Evaluates the given boolean option in the given mode.
+///
+/// If parsing command line arguments, and no value was specified on the command
+/// line, the option's `defaultValue` is used.
+public func <|(mode: CommandMode, option: Option<Bool>) -> Result<Bool> {
+	precondition(option.key != nil)
+
+	switch mode {
+	case let .Arguments(arguments):
+		if let value = arguments.consumeBooleanKey(option.key!) {
+			return success(value)
+		} else if let defaultValue = option.defaultValue {
+			return success(defaultValue)
+		} else {
+			return failure(missingArgumentError(option.description))
+		}
+
+	case .Usage:
+		return failure(informativeUsageError(option))
+	}
+}

	}

	description += "(\(T.name))"

	if option.defaultValue != nil {
		description += "]"

		}
	}

	/// Returns whether the given key was enabled or disabled, or nil if it
	/// was not given at all.
	///
	/// If the key is found, it is then removed from the list of arguments
	/// remaining to be parsed.
	private func consumeBooleanKey(key: String) -> Bool? {
		let oldArguments = rawArguments
		rawArguments.removeAll()

		var result: Bool?
		for arg in oldArguments {
			if arg == .Key(key) {
				result = true
			} else if arg == .Key("no-\(key)") {
				result = false
			} else {
				rawArguments.append(arg)
			}
		}

		return result
	}

	/// Returns the value associated with the given flag, or nil if the flag was
