diff options
Diffstat (limited to 'compiler/commands.nim')
-rw-r--r-- | compiler/commands.nim | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/commands.nim b/compiler/commands.nim index 4a88137b9..994442af0 100644 --- a/compiler/commands.nim +++ b/compiler/commands.nim @@ -106,7 +106,7 @@ proc writeCommandLineUsage*(conf: ConfigRef) = msgWriteln(conf, getCommandLineDesc(conf), {msgStdout}) proc addPrefix(switch: string): string = - if len(switch) == 1: result = "-" & switch + if len(switch) <= 1: result = "-" & switch else: result = "--" & switch const @@ -770,6 +770,8 @@ proc processSwitch*(switch, arg: string, pass: TCmdLinePass, info: TLineInfo; processOnOffSwitchG(conf, {optDocInternal}, arg, pass, info) of "multimethods": processOnOffSwitchG(conf, {optMultiMethods}, arg, pass, info) + of "": + conf.projectName = "-" else: if strutils.find(switch, '.') >= 0: options.setConfigVar(conf, switch, arg) else: invalidCmdLineOption(conf, pass, switch, info) |