From e2c2380d3e0bc3833177bdd0ea6dd939672b96f1 Mon Sep 17 00:00:00 2001 From: TeaDrivenDev Date: Mon, 10 Jul 2017 03:49:01 +0200 Subject: [PATCH] Add Attribute suffix to GatherUnrecognized type name --- src/Argu/Attributes.fs | 2 +- src/Argu/PreCompute.fs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Argu/Attributes.fs b/src/Argu/Attributes.fs index 365adf8d..325b54d1 100644 --- a/src/Argu/Attributes.fs +++ b/src/Argu/Attributes.fs @@ -38,7 +38,7 @@ type InheritAttribute() = inherit Attribute() /// Denotes that the given argument should accummulate any unrecognized arguments it encounters. /// Must contain a single field of type string [] -type GatherUnrecognized() = inherit Attribute() +type GatherUnrecognizedAttribute() = inherit Attribute() /// Demands that at least one subcommand is specified in the CLI; a parse exception is raised otherwise. [] diff --git a/src/Argu/PreCompute.fs b/src/Argu/PreCompute.fs index 492b5dfd..d52fb6d0 100644 --- a/src/Argu/PreCompute.fs +++ b/src/Argu/PreCompute.fs @@ -278,7 +278,7 @@ let rec private preComputeUnionCaseArgInfo (stack : Type list) (helpParam : Help | None -> None let isGatherUnrecognized = - if uci.ContainsAttribute() then + if uci.ContainsAttribute() then match types with | _ when isMainCommand -> arguExn "parameter '%O' contains incompatible combination of attributes 'MainCommand' and 'GatherUnrecognized'." uci | [|t|] when t = typeof -> true