From cbce7cc74e038575efcaab02438d8eb1355bbd18 Mon Sep 17 00:00:00 2001 From: Doug Kearns Date: Mon, 25 Jun 2007 12:53:22 +0000 Subject: [PATCH] make :set display an error message and abort if an explicit value is specified for a boolean option --- chrome/content/vimperator/commands.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/chrome/content/vimperator/commands.js b/chrome/content/vimperator/commands.js index 1c12a949..3a074f64 100644 --- a/chrome/content/vimperator/commands.js +++ b/chrome/content/vimperator/commands.js @@ -1610,7 +1610,10 @@ function set(args, special) var type = option.type; if (type == "boolean") { - option.value = !no; + if (matches[4]) + vimperator.echoerr("E474: Invalid argument: " + option.name + "=" + val); + else + option.value = !no; } else if (type == "number") {