@optique/core 1.0.0-dev.506 → 1.0.0-dev.509
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/constructs.d.cts +84 -643
- package/dist/constructs.d.ts +84 -643
- package/package.json +1 -1
package/dist/constructs.d.cts
CHANGED
|
@@ -823,125 +823,57 @@ interface LongestMatchErrorOptions {
|
|
|
823
823
|
*/
|
|
824
824
|
suggestions?: (suggestions: readonly string[]) => Message;
|
|
825
825
|
}
|
|
826
|
+
type LongestMatchParserArity = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15;
|
|
827
|
+
type LongestMatchArityLimitError = {
|
|
828
|
+
readonly __optiqueLongestMatchArityLimit: "longestMatch() requires between 1 and 15 parser arguments. Nest longestMatch() to combine more.";
|
|
829
|
+
};
|
|
830
|
+
type LongestMatchTailOptions = LongestMatchOptions & {
|
|
831
|
+
readonly $valueType?: never;
|
|
832
|
+
};
|
|
833
|
+
type TupleKeys<T extends readonly unknown[]> = Exclude<keyof T, keyof readonly unknown[]>;
|
|
834
|
+
type LongestMatchTupleState<TParsers extends readonly Parser<Mode, unknown, unknown>[]> = { [K in TupleKeys<TParsers>]: TParsers[K] extends Parser<Mode, unknown, infer TState> ? K extends `${infer TIndex extends number}` ? [TIndex, ParserResult<TState>] : never : never }[TupleKeys<TParsers>];
|
|
835
|
+
type LongestMatchState<TParsers extends readonly Parser<Mode, unknown, unknown>[]> = IsTuple<TParsers> extends true ? undefined | LongestMatchTupleState<TParsers> : undefined | [number, ParserResult<unknown>];
|
|
836
|
+
type LongestMatchArityGuard<TParsers extends readonly unknown[]> = IsTuple<TParsers> extends true ? TParsers["length"] extends LongestMatchParserArity ? unknown : LongestMatchArityLimitError : unknown;
|
|
826
837
|
/**
|
|
827
|
-
* Creates a parser that
|
|
828
|
-
*
|
|
829
|
-
*
|
|
830
|
-
*
|
|
831
|
-
* @
|
|
832
|
-
*
|
|
833
|
-
* @template TA The type of the value returned by the first parser.
|
|
834
|
-
* @template TB The type of the value returned by the second parser.
|
|
835
|
-
* @template TStateA The type of the state used by the first parser.
|
|
836
|
-
* @template TStateB The type of the state used by the second parser.
|
|
837
|
-
* @param a The first {@link Parser} to try.
|
|
838
|
-
* @param b The second {@link Parser} to try.
|
|
839
|
-
* @returns A {@link Parser} that tries to parse using both parsers
|
|
840
|
-
* and returns the result of the parser that consumed more tokens.
|
|
841
|
-
* @since 0.3.0
|
|
842
|
-
*/
|
|
843
|
-
declare function longestMatch<MA extends Mode, MB extends Mode, TA, TB, TStateA, TStateB>(a: Parser<MA, TA, TStateA>, b: Parser<MB, TB, TStateB>): Parser<CombineModes<readonly [MA, MB]>, TA | TB, undefined | [0, ParserResult<TStateA>] | [1, ParserResult<TStateB>]>;
|
|
844
|
-
/**
|
|
845
|
-
* Creates a parser that combines three mutually exclusive parsers into one,
|
|
846
|
-
* selecting the parser that consumes the most tokens.
|
|
847
|
-
* The resulting parser will try all parsers and return the result
|
|
848
|
-
* of the parser that consumed the most input tokens.
|
|
849
|
-
* @template MA The mode of the first parser.
|
|
850
|
-
* @template MB The mode of the second parser.
|
|
851
|
-
* @template MC The mode of the third parser.
|
|
852
|
-
* @template TA The type of the value returned by the first parser.
|
|
853
|
-
* @template TB The type of the value returned by the second parser.
|
|
854
|
-
* @template TC The type of the value returned by the third parser.
|
|
855
|
-
* @template TStateA The type of the state used by the first parser.
|
|
856
|
-
* @template TStateB The type of the state used by the second parser.
|
|
857
|
-
* @template TStateC The type of the state used by the third parser.
|
|
858
|
-
* @param a The first {@link Parser} to try.
|
|
859
|
-
* @param b The second {@link Parser} to try.
|
|
860
|
-
* @param c The third {@link Parser} to try.
|
|
861
|
-
* @returns A {@link Parser} that tries to parse using all parsers
|
|
862
|
-
* and returns the result of the parser that consumed the most tokens.
|
|
863
|
-
* @since 0.3.0
|
|
864
|
-
*/
|
|
865
|
-
declare function longestMatch<MA extends Mode, MB extends Mode, MC extends Mode, TA, TB, TC, TStateA, TStateB, TStateC>(a: Parser<MA, TA, TStateA>, b: Parser<MB, TB, TStateB>, c: Parser<MC, TC, TStateC>): Parser<CombineModes<readonly [MA, MB, MC]>, TA | TB | TC, undefined | [0, ParserResult<TStateA>] | [1, ParserResult<TStateB>] | [2, ParserResult<TStateC>]>;
|
|
866
|
-
/**
|
|
867
|
-
* Creates a parser that combines four mutually exclusive parsers into one,
|
|
868
|
-
* selecting the parser that consumes the most tokens.
|
|
869
|
-
* The resulting parser will try all parsers and return the result
|
|
870
|
-
* of the parser that consumed the most input tokens.
|
|
871
|
-
* @template MA The mode of the first parser.
|
|
872
|
-
* @template MB The mode of the second parser.
|
|
873
|
-
* @template MC The mode of the third parser.
|
|
874
|
-
* @template MD The mode of the fourth parser.
|
|
875
|
-
* @template TA The type of the value returned by the first parser.
|
|
876
|
-
* @template TB The type of the value returned by the second parser.
|
|
877
|
-
* @template TC The type of the value returned by the third parser.
|
|
878
|
-
* @template TD The type of the value returned by the fourth parser.
|
|
879
|
-
* @template TStateA The type of the state used by the first parser.
|
|
880
|
-
* @template TStateB The type of the state used by the second parser.
|
|
881
|
-
* @template TStateC The type of the state used by the third parser.
|
|
882
|
-
* @template TStateD The type of the state used by the fourth parser.
|
|
883
|
-
* @param a The first {@link Parser} to try.
|
|
884
|
-
* @param b The second {@link Parser} to try.
|
|
885
|
-
* @param c The third {@link Parser} to try.
|
|
886
|
-
* @param d The fourth {@link Parser} to try.
|
|
887
|
-
* @returns A {@link Parser} that tries to parse using all parsers
|
|
888
|
-
* and returns the result of the parser that consumed the most tokens.
|
|
838
|
+
* Creates a parser that selects the successful branch that consumed
|
|
839
|
+
* the most input tokens.
|
|
840
|
+
*
|
|
841
|
+
* @param parsers Parsers to evaluate and compare by consumed input.
|
|
842
|
+
* @returns A parser that yields the best successful branch result.
|
|
843
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
889
844
|
* @since 0.3.0
|
|
890
845
|
*/
|
|
891
|
-
declare function longestMatch<
|
|
846
|
+
declare function longestMatch<const TParsers extends readonly Parser<"sync", unknown, unknown>[]>(...parsers: TParsers & LongestMatchArityGuard<TParsers>): Parser<"sync", InferValue<TParsers[number]>, LongestMatchState<TParsers>>;
|
|
892
847
|
/**
|
|
893
|
-
* Creates a parser that
|
|
894
|
-
*
|
|
895
|
-
*
|
|
896
|
-
*
|
|
897
|
-
* @
|
|
898
|
-
*
|
|
899
|
-
* @template MC The mode of the third parser.
|
|
900
|
-
* @template MD The mode of the fourth parser.
|
|
901
|
-
* @template ME The mode of the fifth parser.
|
|
902
|
-
* @template TA The type of the value returned by the first parser.
|
|
903
|
-
* @template TB The type of the value returned by the second parser.
|
|
904
|
-
* @template TC The type of the value returned by the third parser.
|
|
905
|
-
* @template TD The type of the value returned by the fourth parser.
|
|
906
|
-
* @template TE The type of the value returned by the fifth parser.
|
|
907
|
-
* @template TStateA The type of the state used by the first parser.
|
|
908
|
-
* @template TStateB The type of the state used by the second parser.
|
|
909
|
-
* @template TStateC The type of the state used by the third parser.
|
|
910
|
-
* @template TStateD The type of the state used by the fourth parser.
|
|
911
|
-
* @template TStateE The type of the state used by the fifth parser.
|
|
912
|
-
* @param a The first {@link Parser} to try.
|
|
913
|
-
* @param b The second {@link Parser} to try.
|
|
914
|
-
* @param c The third {@link Parser} to try.
|
|
915
|
-
* @param d The fourth {@link Parser} to try.
|
|
916
|
-
* @param e The fifth {@link Parser} to try.
|
|
917
|
-
* @returns A {@link Parser} that tries to parse using all parsers
|
|
918
|
-
* and returns the result of the parser that consumed the most tokens.
|
|
848
|
+
* Creates a parser that selects the successful branch that consumed
|
|
849
|
+
* the most input tokens.
|
|
850
|
+
*
|
|
851
|
+
* @param parsers Parsers to evaluate and compare by consumed input.
|
|
852
|
+
* @returns A parser that yields the best successful branch result.
|
|
853
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
919
854
|
* @since 0.3.0
|
|
920
855
|
*/
|
|
921
|
-
declare function longestMatch<
|
|
922
|
-
/**
|
|
923
|
-
* Creates a parser that combines two mutually exclusive parsers into one,
|
|
924
|
-
* with custom error message options.
|
|
925
|
-
* @since 0.5.0
|
|
926
|
-
*/
|
|
927
|
-
declare function longestMatch<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>>(a: TA, b: TB, options: LongestMatchOptions): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>]>, InferValue<TA> | InferValue<TB>, undefined | [number, ParserResult<unknown>]>;
|
|
856
|
+
declare function longestMatch<const TParsers extends readonly Parser<Mode, unknown, unknown>[]>(...parsers: TParsers & LongestMatchArityGuard<TParsers>): Parser<CombineModes<{ readonly [K in keyof TParsers]: ExtractMode<TParsers[K]> }>, InferValue<TParsers[number]>, LongestMatchState<TParsers>>;
|
|
928
857
|
/**
|
|
929
|
-
* Creates a parser that
|
|
930
|
-
* with custom error
|
|
858
|
+
* Creates a parser that selects the successful branch that consumed
|
|
859
|
+
* the most input tokens, with custom error options.
|
|
860
|
+
*
|
|
861
|
+
* @param rest Parsers to compare, followed by error customization options.
|
|
862
|
+
* @returns A parser that yields the best successful branch result.
|
|
863
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
931
864
|
* @since 0.5.0
|
|
932
865
|
*/
|
|
933
|
-
declare function longestMatch<
|
|
934
|
-
declare function longestMatch(...parsers: Parser<Mode, unknown, unknown>[]): Parser<Mode, unknown, undefined | [number, ParserResult<unknown>]>;
|
|
866
|
+
declare function longestMatch<const TParsers extends readonly Parser<"sync", unknown, unknown>[]>(...rest: [...parsers: TParsers, options: LongestMatchTailOptions] & LongestMatchArityGuard<TParsers>): Parser<"sync", InferValue<TParsers[number]>, LongestMatchState<TParsers>>;
|
|
935
867
|
/**
|
|
936
|
-
* Creates a parser that
|
|
937
|
-
* the most input, with custom error
|
|
938
|
-
*
|
|
939
|
-
* @param rest
|
|
940
|
-
* @returns A parser that
|
|
941
|
-
*
|
|
868
|
+
* Creates a parser that selects the successful branch that consumed
|
|
869
|
+
* the most input tokens, with custom error options.
|
|
870
|
+
*
|
|
871
|
+
* @param rest Parsers to compare, followed by error customization options.
|
|
872
|
+
* @returns A parser that yields the best successful branch result.
|
|
873
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
942
874
|
* @since 0.5.0
|
|
943
875
|
*/
|
|
944
|
-
declare function longestMatch
|
|
876
|
+
declare function longestMatch<const TParsers extends readonly Parser<Mode, unknown, unknown>[]>(...rest: [...parsers: TParsers, options: LongestMatchTailOptions] & LongestMatchArityGuard<TParsers>): Parser<CombineModes<{ readonly [K in keyof TParsers]: ExtractMode<TParsers[K]> }>, InferValue<TParsers[number]>, LongestMatchState<TParsers>>;
|
|
945
877
|
/**
|
|
946
878
|
* Options for the {@link object} parser.
|
|
947
879
|
* @since 0.5.0
|
|
@@ -1143,555 +1075,64 @@ interface MergeOptions {
|
|
|
1143
1075
|
*/
|
|
1144
1076
|
readonly hidden?: HiddenVisibility;
|
|
1145
1077
|
}
|
|
1078
|
+
type MergeParserArity = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15;
|
|
1079
|
+
type MergeArityLimitError = {
|
|
1080
|
+
readonly __optiqueMergeArityLimit: "merge() requires between 1 and 15 parser arguments. Nest merge() to combine more.";
|
|
1081
|
+
};
|
|
1082
|
+
type MergeTailOptions = MergeOptions & {
|
|
1083
|
+
readonly $valueType?: never;
|
|
1084
|
+
};
|
|
1085
|
+
type MergeArityGuard<TParsers extends readonly unknown[]> = IsTuple<TParsers> extends true ? TParsers["length"] extends MergeParserArity ? unknown : MergeArityLimitError : unknown;
|
|
1086
|
+
type MergeParsers = readonly Parser<Mode, unknown, unknown>[];
|
|
1087
|
+
type EnsureMergeParsers<TParsers extends MergeParsers> = { readonly [K in keyof TParsers]: ExtractObjectTypes<TParsers[K]> extends never ? never : TParsers[K] };
|
|
1088
|
+
type MergeValues<TParsers extends MergeParsers> = TParsers extends readonly [infer THead extends Parser<Mode, unknown, unknown>, ...infer TRest extends MergeParsers] ? ExtractObjectTypes<THead> & MergeValues<TRest> : Record<string | symbol, unknown>;
|
|
1089
|
+
type MergeReturnType<TParsers extends MergeParsers> = Parser<CombineModes<{ readonly [K in keyof TParsers]: ExtractMode<TParsers[K]> }>, MergeValues<TParsers>, Record<string | symbol, unknown>>;
|
|
1146
1090
|
/**
|
|
1147
|
-
* Merges multiple
|
|
1148
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1149
|
-
* the unified parser produces a single object containing all the values
|
|
1150
|
-
* from the individual parsers while separating the fields into multiple
|
|
1151
|
-
* groups.
|
|
1152
|
-
* @template TA The type of the first parser.
|
|
1153
|
-
* @template TB The type of the second parser.
|
|
1154
|
-
* @param a The first {@link object} parser to merge.
|
|
1155
|
-
* @param b The second {@link object} parser to merge.
|
|
1156
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1157
|
-
* of the two parsers into a single object.
|
|
1158
|
-
*/
|
|
1159
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB>, Record<string | symbol, unknown>>;
|
|
1160
|
-
/**
|
|
1161
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1162
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1163
|
-
* the unified parser produces a single object containing all the values
|
|
1164
|
-
* from the individual parsers while separating the fields into multiple
|
|
1165
|
-
* groups.
|
|
1166
|
-
* @template TA The type of the first parser.
|
|
1167
|
-
* @template TB The type of the second parser.
|
|
1168
|
-
* @param a The first {@link object} parser to merge.
|
|
1169
|
-
* @param b The second {@link object} parser to merge.
|
|
1170
|
-
* @param options Optional configuration for the merge parser.
|
|
1171
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1172
|
-
* of the two parsers into a single object.
|
|
1173
|
-
*/
|
|
1174
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, options: MergeOptions): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB>, Record<string | symbol, unknown>>;
|
|
1175
|
-
/**
|
|
1176
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1177
|
-
* with a label for documentation and help text organization.
|
|
1178
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1179
|
-
* the unified parser produces a single object containing all the values
|
|
1180
|
-
* from the individual parsers while separating the fields into multiple
|
|
1181
|
-
* groups.
|
|
1182
|
-
* @template TA The type of the first parser.
|
|
1183
|
-
* @template TB The type of the second parser.
|
|
1184
|
-
* @param label A descriptive label for this merged group, used for
|
|
1185
|
-
* documentation and help messages.
|
|
1186
|
-
* @param a The first {@link object} parser to merge.
|
|
1187
|
-
* @param b The second {@link object} parser to merge.
|
|
1188
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1189
|
-
* of the two parsers into a single object.
|
|
1190
|
-
*/
|
|
1191
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB>, Record<string | symbol, unknown>>;
|
|
1192
|
-
/**
|
|
1193
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1194
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1195
|
-
* the unified parser produces a single object containing all the values
|
|
1196
|
-
* from the individual parsers while separating the fields into multiple
|
|
1197
|
-
* groups.
|
|
1198
|
-
* @template TA The type of the first parser.
|
|
1199
|
-
* @template TB The type of the second parser.
|
|
1200
|
-
* @template TC The type of the third parser.
|
|
1201
|
-
* @param a The first {@link object} parser to merge.
|
|
1202
|
-
* @param b The second {@link object} parser to merge.
|
|
1203
|
-
* @param c The third {@link object} parser to merge.
|
|
1204
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1205
|
-
* of the two parsers into a single object.
|
|
1206
|
-
*/
|
|
1207
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC>, Record<string | symbol, unknown>>;
|
|
1208
|
-
/**
|
|
1209
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1210
|
-
* with a label for documentation and help text organization.
|
|
1211
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1212
|
-
* the unified parser produces a single object containing all the values
|
|
1213
|
-
* from the individual parsers while separating the fields into multiple
|
|
1214
|
-
* groups.
|
|
1215
|
-
* @template TA The type of the first parser.
|
|
1216
|
-
* @template TB The type of the second parser.
|
|
1217
|
-
* @template TC The type of the third parser.
|
|
1218
|
-
* @param label A descriptive label for this merged group, used for
|
|
1219
|
-
* documentation and help messages.
|
|
1220
|
-
* @param a The first {@link object} parser to merge.
|
|
1221
|
-
* @param b The second {@link object} parser to merge.
|
|
1222
|
-
* @param c The third {@link object} parser to merge.
|
|
1223
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1224
|
-
* of the two parsers into a single object.
|
|
1225
|
-
*/
|
|
1226
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC>, Record<string | symbol, unknown>>;
|
|
1227
|
-
/**
|
|
1228
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1229
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1230
|
-
* the unified parser produces a single object containing all the values
|
|
1231
|
-
* from the individual parsers while separating the fields into multiple
|
|
1232
|
-
* groups.
|
|
1233
|
-
* @template TA The type of the first parser.
|
|
1234
|
-
* @template TB The type of the second parser.
|
|
1235
|
-
* @template TC The type of the third parser.
|
|
1236
|
-
* @template TD The type of the fourth parser.
|
|
1237
|
-
* @param a The first {@link object} parser to merge.
|
|
1238
|
-
* @param b The second {@link object} parser to merge.
|
|
1239
|
-
* @param c The third {@link object} parser to merge.
|
|
1240
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1241
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1242
|
-
* of the two parsers into a single object.
|
|
1243
|
-
*/
|
|
1244
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD>, Record<string | symbol, unknown>>;
|
|
1245
|
-
/**
|
|
1246
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1247
|
-
* with a label for documentation and help text organization.
|
|
1248
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1249
|
-
* the unified parser produces a single object containing all the values
|
|
1250
|
-
* from the individual parsers while separating the fields into multiple
|
|
1251
|
-
* groups.
|
|
1252
|
-
* @template TA The type of the first parser.
|
|
1253
|
-
* @template TB The type of the second parser.
|
|
1254
|
-
* @template TC The type of the third parser.
|
|
1255
|
-
* @template TD The type of the fourth parser.
|
|
1256
|
-
* @param label A descriptive label for this merged group, used for
|
|
1257
|
-
* documentation and help messages.
|
|
1258
|
-
* @param a The first {@link object} parser to merge.
|
|
1259
|
-
* @param b The second {@link object} parser to merge.
|
|
1260
|
-
* @param c The third {@link object} parser to merge.
|
|
1261
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1262
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1263
|
-
* of the two parsers into a single object.
|
|
1264
|
-
*/
|
|
1265
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD>, Record<string | symbol, unknown>>;
|
|
1266
|
-
/**
|
|
1267
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1268
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1269
|
-
* the unified parser produces a single object containing all the values
|
|
1270
|
-
* from the individual parsers while separating the fields into multiple
|
|
1271
|
-
* groups.
|
|
1272
|
-
* @template TA The type of the first parser.
|
|
1273
|
-
* @template TB The type of the second parser.
|
|
1274
|
-
* @template TC The type of the third parser.
|
|
1275
|
-
* @template TD The type of the fourth parser.
|
|
1276
|
-
* @template TE The type of the fifth parser.
|
|
1277
|
-
* @param a The first {@link object} parser to merge.
|
|
1278
|
-
* @param b The second {@link object} parser to merge.
|
|
1279
|
-
* @param c The third {@link object} parser to merge.
|
|
1280
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1281
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1282
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1283
|
-
* of the two parsers into a single object.
|
|
1284
|
-
*/
|
|
1285
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE>, Record<string | symbol, unknown>>;
|
|
1286
|
-
/**
|
|
1287
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1288
|
-
* with a label for documentation and help text organization.
|
|
1289
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1290
|
-
* the unified parser produces a single object containing all the values
|
|
1291
|
-
* from the individual parsers while separating the fields into multiple
|
|
1292
|
-
* groups.
|
|
1293
|
-
* @template TA The type of the first parser.
|
|
1294
|
-
* @template TB The type of the second parser.
|
|
1295
|
-
* @template TC The type of the third parser.
|
|
1296
|
-
* @template TD The type of the fourth parser.
|
|
1297
|
-
* @template TE The type of the fifth parser.
|
|
1298
|
-
* @param label A descriptive label for this merged group, used for
|
|
1299
|
-
* documentation and help messages.
|
|
1300
|
-
* @param a The first {@link object} parser to merge.
|
|
1301
|
-
* @param b The second {@link object} parser to merge.
|
|
1302
|
-
* @param c The third {@link object} parser to merge.
|
|
1303
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1304
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1305
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1306
|
-
* of the two parsers into a single object.
|
|
1307
|
-
*/
|
|
1308
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE>, Record<string | symbol, unknown>>;
|
|
1309
|
-
/**
|
|
1310
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1311
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1312
|
-
* the unified parser produces a single object containing all the values
|
|
1313
|
-
* from the individual parsers while separating the fields into multiple
|
|
1314
|
-
* groups.
|
|
1315
|
-
* @template TA The type of the first parser.
|
|
1316
|
-
* @template TB The type of the second parser.
|
|
1317
|
-
* @template TC The type of the third parser.
|
|
1318
|
-
* @template TD The type of the fourth parser.
|
|
1319
|
-
* @template TE The type of the fifth parser.
|
|
1320
|
-
* @template TF The type of the sixth parser.
|
|
1321
|
-
* @param a The first {@link object} parser to merge.
|
|
1322
|
-
* @param b The second {@link object} parser to merge.
|
|
1323
|
-
* @param c The third {@link object} parser to merge.
|
|
1324
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1325
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1326
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1327
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1328
|
-
* of the parsers into a single object.
|
|
1329
|
-
* @since 0.4.0
|
|
1330
|
-
*/
|
|
1331
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF>, Record<string | symbol, unknown>>;
|
|
1332
|
-
/**
|
|
1333
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1334
|
-
* with a label for documentation and help text organization.
|
|
1335
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1336
|
-
* the unified parser produces a single object containing all the values
|
|
1337
|
-
* from the individual parsers while separating the fields into multiple
|
|
1338
|
-
* groups.
|
|
1339
|
-
* @template TA The type of the first parser.
|
|
1340
|
-
* @template TB The type of the second parser.
|
|
1341
|
-
* @template TC The type of the third parser.
|
|
1342
|
-
* @template TD The type of the fourth parser.
|
|
1343
|
-
* @template TE The type of the fifth parser.
|
|
1344
|
-
* @template TF The type of the sixth parser.
|
|
1345
|
-
* @param label A descriptive label for this merged group, used for
|
|
1346
|
-
* documentation and help messages.
|
|
1347
|
-
* @param a The first {@link object} parser to merge.
|
|
1348
|
-
* @param b The second {@link object} parser to merge.
|
|
1349
|
-
* @param c The third {@link object} parser to merge.
|
|
1350
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1351
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1352
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1353
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1354
|
-
* of the parsers into a single object.
|
|
1355
|
-
* @since 0.4.0
|
|
1356
|
-
*/
|
|
1357
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF>, Record<string | symbol, unknown>>;
|
|
1358
|
-
/**
|
|
1359
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1360
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1361
|
-
* the unified parser produces a single object containing all the values
|
|
1362
|
-
* from the individual parsers while separating the fields into multiple
|
|
1363
|
-
* groups.
|
|
1364
|
-
* @template TA The type of the first parser.
|
|
1365
|
-
* @template TB The type of the second parser.
|
|
1366
|
-
* @template TC The type of the third parser.
|
|
1367
|
-
* @template TD The type of the fourth parser.
|
|
1368
|
-
* @template TE The type of the fifth parser.
|
|
1369
|
-
* @template TF The type of the sixth parser.
|
|
1370
|
-
* @template TG The type of the seventh parser.
|
|
1371
|
-
* @param a The first {@link object} parser to merge.
|
|
1372
|
-
* @param b The second {@link object} parser to merge.
|
|
1373
|
-
* @param c The third {@link object} parser to merge.
|
|
1374
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1375
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1376
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1377
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1378
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1379
|
-
* of the parsers into a single object.
|
|
1380
|
-
* @since 0.4.0
|
|
1381
|
-
*/
|
|
1382
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG>, Record<string | symbol, unknown>>;
|
|
1383
|
-
/**
|
|
1384
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1385
|
-
* with a label for documentation and help text organization.
|
|
1386
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1387
|
-
* the unified parser produces a single object containing all the values
|
|
1388
|
-
* from the individual parsers while separating the fields into multiple
|
|
1389
|
-
* groups.
|
|
1390
|
-
* @template TA The type of the first parser.
|
|
1391
|
-
* @template TB The type of the second parser.
|
|
1392
|
-
* @template TC The type of the third parser.
|
|
1393
|
-
* @template TD The type of the fourth parser.
|
|
1394
|
-
* @template TE The type of the fifth parser.
|
|
1395
|
-
* @template TF The type of the sixth parser.
|
|
1396
|
-
* @template TG The type of the seventh parser.
|
|
1397
|
-
* @param label A descriptive label for this merged group, used for
|
|
1398
|
-
* documentation and help messages.
|
|
1399
|
-
* @param a The first {@link object} parser to merge.
|
|
1400
|
-
* @param b The second {@link object} parser to merge.
|
|
1401
|
-
* @param c The third {@link object} parser to merge.
|
|
1402
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1403
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1404
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1405
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1406
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1407
|
-
* of the parsers into a single object.
|
|
1408
|
-
* @since 0.4.0
|
|
1409
|
-
*/
|
|
1410
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG>, Record<string | symbol, unknown>>;
|
|
1411
|
-
/**
|
|
1412
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1413
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1414
|
-
* the unified parser produces a single object containing all the values
|
|
1415
|
-
* from the individual parsers while separating the fields into multiple
|
|
1416
|
-
* groups.
|
|
1417
|
-
* @template TA The type of the first parser.
|
|
1418
|
-
* @template TB The type of the second parser.
|
|
1419
|
-
* @template TC The type of the third parser.
|
|
1420
|
-
* @template TD The type of the fourth parser.
|
|
1421
|
-
* @template TE The type of the fifth parser.
|
|
1422
|
-
* @template TF The type of the sixth parser.
|
|
1423
|
-
* @template TG The type of the seventh parser.
|
|
1424
|
-
* @template TH The type of the eighth parser.
|
|
1425
|
-
* @param a The first {@link object} parser to merge.
|
|
1426
|
-
* @param b The second {@link object} parser to merge.
|
|
1427
|
-
* @param c The third {@link object} parser to merge.
|
|
1428
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1429
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1430
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1431
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1432
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1433
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1434
|
-
* of the parsers into a single object.
|
|
1435
|
-
* @since 0.4.0
|
|
1436
|
-
*/
|
|
1437
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH>, Record<string | symbol, unknown>>;
|
|
1438
|
-
/**
|
|
1439
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1440
|
-
* with a label for documentation and help text organization.
|
|
1441
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1442
|
-
* the unified parser produces a single object containing all the values
|
|
1443
|
-
* from the individual parsers while separating the fields into multiple
|
|
1444
|
-
* groups.
|
|
1445
|
-
* @template TA The type of the first parser.
|
|
1446
|
-
* @template TB The type of the second parser.
|
|
1447
|
-
* @template TC The type of the third parser.
|
|
1448
|
-
* @template TD The type of the fourth parser.
|
|
1449
|
-
* @template TE The type of the fifth parser.
|
|
1450
|
-
* @template TF The type of the sixth parser.
|
|
1451
|
-
* @template TG The type of the seventh parser.
|
|
1452
|
-
* @template TH The type of the eighth parser.
|
|
1453
|
-
* @param label A descriptive label for this merged group, used for
|
|
1454
|
-
* documentation and help messages.
|
|
1455
|
-
* @param a The first {@link object} parser to merge.
|
|
1456
|
-
* @param b The second {@link object} parser to merge.
|
|
1457
|
-
* @param c The third {@link object} parser to merge.
|
|
1458
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1459
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1460
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1461
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1462
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1463
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1464
|
-
* of the parsers into a single object.
|
|
1465
|
-
* @since 0.4.0
|
|
1466
|
-
*/
|
|
1467
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH>, Record<string | symbol, unknown>>;
|
|
1468
|
-
/**
|
|
1469
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1470
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1471
|
-
* the unified parser produces a single object containing all the values
|
|
1472
|
-
* from the individual parsers while separating the fields into multiple
|
|
1473
|
-
* groups.
|
|
1474
|
-
* @template TA The type of the first parser.
|
|
1475
|
-
* @template TB The type of the second parser.
|
|
1476
|
-
* @template TC The type of the third parser.
|
|
1477
|
-
* @template TD The type of the fourth parser.
|
|
1478
|
-
* @template TE The type of the fifth parser.
|
|
1479
|
-
* @template TF The type of the sixth parser.
|
|
1480
|
-
* @template TG The type of the seventh parser.
|
|
1481
|
-
* @template TH The type of the eighth parser.
|
|
1482
|
-
* @template TI The type of the ninth parser.
|
|
1483
|
-
* @param a The first {@link object} parser to merge.
|
|
1484
|
-
* @param b The second {@link object} parser to merge.
|
|
1485
|
-
* @param c The third {@link object} parser to merge.
|
|
1486
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1487
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1488
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1489
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1490
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1491
|
-
* @param i The ninth {@link object} parser to merge.
|
|
1492
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1493
|
-
* of the parsers into a single object.
|
|
1494
|
-
* @since 0.4.0
|
|
1495
|
-
*/
|
|
1496
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>, TI extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH, i: ExtractObjectTypes<TI> extends never ? never : TI): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>, ExtractMode<TI>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH> & ExtractObjectTypes<TI>, Record<string | symbol, unknown>>;
|
|
1497
|
-
/**
|
|
1498
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1499
|
-
* with a label for documentation and help text organization.
|
|
1500
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1501
|
-
* the unified parser produces a single object containing all the values
|
|
1502
|
-
* from the individual parsers while separating the fields into multiple
|
|
1503
|
-
* groups.
|
|
1504
|
-
* @template TA The type of the first parser.
|
|
1505
|
-
* @template TB The type of the second parser.
|
|
1506
|
-
* @template TC The type of the third parser.
|
|
1507
|
-
* @template TD The type of the fourth parser.
|
|
1508
|
-
* @template TE The type of the fifth parser.
|
|
1509
|
-
* @template TF The type of the sixth parser.
|
|
1510
|
-
* @template TG The type of the seventh parser.
|
|
1511
|
-
* @template TH The type of the eighth parser.
|
|
1512
|
-
* @template TI The type of the ninth parser.
|
|
1513
|
-
* @param label A descriptive label for this merged group, used for
|
|
1514
|
-
* documentation and help messages.
|
|
1515
|
-
* @param a The first {@link object} parser to merge.
|
|
1516
|
-
* @param b The second {@link object} parser to merge.
|
|
1517
|
-
* @param c The third {@link object} parser to merge.
|
|
1518
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1519
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1520
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1521
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1522
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1523
|
-
* @param i The ninth {@link object} parser to merge.
|
|
1524
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1525
|
-
* of the parsers into a single object.
|
|
1526
|
-
* @since 0.4.0
|
|
1527
|
-
*/
|
|
1528
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>, TI extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH, i: ExtractObjectTypes<TI> extends never ? never : TI): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>, ExtractMode<TI>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH> & ExtractObjectTypes<TI>, Record<string | symbol, unknown>>;
|
|
1529
|
-
/**
|
|
1530
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser.
|
|
1531
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1532
|
-
* the unified parser produces a single object containing all the values
|
|
1533
|
-
* from the individual parsers while separating the fields into multiple
|
|
1534
|
-
* groups.
|
|
1535
|
-
* @template TA The type of the first parser.
|
|
1536
|
-
* @template TB The type of the second parser.
|
|
1537
|
-
* @template TC The type of the third parser.
|
|
1538
|
-
* @template TD The type of the fourth parser.
|
|
1539
|
-
* @template TE The type of the fifth parser.
|
|
1540
|
-
* @template TF The type of the sixth parser.
|
|
1541
|
-
* @template TG The type of the seventh parser.
|
|
1542
|
-
* @template TH The type of the eighth parser.
|
|
1543
|
-
* @template TI The type of the ninth parser.
|
|
1544
|
-
* @template TJ The type of the tenth parser.
|
|
1545
|
-
* @param a The first {@link object} parser to merge.
|
|
1546
|
-
* @param b The second {@link object} parser to merge.
|
|
1547
|
-
* @param c The third {@link object} parser to merge.
|
|
1548
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1549
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1550
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1551
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1552
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1553
|
-
* @param i The ninth {@link object} parser to merge.
|
|
1554
|
-
* @param j The tenth {@link object} parser to merge.
|
|
1555
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1556
|
-
* of the parsers into a single object.
|
|
1557
|
-
* @since 0.4.0
|
|
1558
|
-
*/
|
|
1559
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>, TI extends Parser<Mode, unknown, unknown>, TJ extends Parser<Mode, unknown, unknown>>(a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH, i: ExtractObjectTypes<TI> extends never ? never : TI, j: ExtractObjectTypes<TJ> extends never ? never : TJ): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>, ExtractMode<TI>, ExtractMode<TJ>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH> & ExtractObjectTypes<TI> & ExtractObjectTypes<TJ>, Record<string | symbol, unknown>>;
|
|
1560
|
-
/**
|
|
1561
|
-
* Merges multiple {@link object} parsers into a single {@link object} parser
|
|
1562
|
-
* with a label for documentation and help text organization.
|
|
1563
|
-
* It is useful for combining multiple {@link object} parsers so that
|
|
1564
|
-
* the unified parser produces a single object containing all the values
|
|
1565
|
-
* from the individual parsers while separating the fields into multiple
|
|
1566
|
-
* groups.
|
|
1567
|
-
* @template TA The type of the first parser.
|
|
1568
|
-
* @template TB The type of the second parser.
|
|
1569
|
-
* @template TC The type of the third parser.
|
|
1570
|
-
* @template TD The type of the fourth parser.
|
|
1571
|
-
* @template TE The type of the fifth parser.
|
|
1572
|
-
* @template TF The type of the sixth parser.
|
|
1573
|
-
* @template TG The type of the seventh parser.
|
|
1574
|
-
* @template TH The type of the eighth parser.
|
|
1575
|
-
* @template TI The type of the ninth parser.
|
|
1576
|
-
* @template TJ The type of the tenth parser.
|
|
1577
|
-
* @param label A descriptive label for this merged group, used for
|
|
1578
|
-
* documentation and help messages.
|
|
1579
|
-
* @param a The first {@link object} parser to merge.
|
|
1580
|
-
* @param b The second {@link object} parser to merge.
|
|
1581
|
-
* @param c The third {@link object} parser to merge.
|
|
1582
|
-
* @param d The fourth {@link object} parser to merge.
|
|
1583
|
-
* @param e The fifth {@link object} parser to merge.
|
|
1584
|
-
* @param f The sixth {@link object} parser to merge.
|
|
1585
|
-
* @param g The seventh {@link object} parser to merge.
|
|
1586
|
-
* @param h The eighth {@link object} parser to merge.
|
|
1587
|
-
* @param i The ninth {@link object} parser to merge.
|
|
1588
|
-
* @param j The tenth {@link object} parser to merge.
|
|
1589
|
-
* @return A new {@link object} parser that combines the values and states
|
|
1590
|
-
* of the parsers into a single object.
|
|
1591
|
-
* @since 0.4.0
|
|
1592
|
-
*/
|
|
1593
|
-
declare function merge<TA extends Parser<Mode, unknown, unknown>, TB extends Parser<Mode, unknown, unknown>, TC extends Parser<Mode, unknown, unknown>, TD extends Parser<Mode, unknown, unknown>, TE extends Parser<Mode, unknown, unknown>, TF extends Parser<Mode, unknown, unknown>, TG extends Parser<Mode, unknown, unknown>, TH extends Parser<Mode, unknown, unknown>, TI extends Parser<Mode, unknown, unknown>, TJ extends Parser<Mode, unknown, unknown>>(label: string, a: ExtractObjectTypes<TA> extends never ? never : TA, b: ExtractObjectTypes<TB> extends never ? never : TB, c: ExtractObjectTypes<TC> extends never ? never : TC, d: ExtractObjectTypes<TD> extends never ? never : TD, e: ExtractObjectTypes<TE> extends never ? never : TE, f: ExtractObjectTypes<TF> extends never ? never : TF, g: ExtractObjectTypes<TG> extends never ? never : TG, h: ExtractObjectTypes<TH> extends never ? never : TH, i: ExtractObjectTypes<TI> extends never ? never : TI, j: ExtractObjectTypes<TJ> extends never ? never : TJ): Parser<CombineModes<readonly [ExtractMode<TA>, ExtractMode<TB>, ExtractMode<TC>, ExtractMode<TD>, ExtractMode<TE>, ExtractMode<TF>, ExtractMode<TG>, ExtractMode<TH>, ExtractMode<TI>, ExtractMode<TJ>]>, ExtractObjectTypes<TA> & ExtractObjectTypes<TB> & ExtractObjectTypes<TC> & ExtractObjectTypes<TD> & ExtractObjectTypes<TE> & ExtractObjectTypes<TF> & ExtractObjectTypes<TG> & ExtractObjectTypes<TH> & ExtractObjectTypes<TI> & ExtractObjectTypes<TJ>, Record<string | symbol, unknown>>;
|
|
1594
|
-
/**
|
|
1595
|
-
* Concatenates two {@link tuple} parsers into a single parser that produces
|
|
1596
|
-
* a flattened tuple containing the values from both parsers in order.
|
|
1597
|
-
*
|
|
1598
|
-
* This is similar to {@link merge} for object parsers, but operates on tuple
|
|
1599
|
-
* parsers and preserves the sequential, positional nature of tuples by
|
|
1600
|
-
* flattening the results into a single tuple array.
|
|
1601
|
-
*
|
|
1602
|
-
* @example
|
|
1603
|
-
* ```typescript
|
|
1604
|
-
* const basicTuple = tuple([
|
|
1605
|
-
* option("-v", "--verbose"),
|
|
1606
|
-
* option("-p", "--port", integer()),
|
|
1607
|
-
* ]);
|
|
1608
|
-
*
|
|
1609
|
-
* const serverTuple = tuple([
|
|
1610
|
-
* option("-h", "--host", string()),
|
|
1611
|
-
* option("-d", "--debug"),
|
|
1612
|
-
* ]);
|
|
1613
|
-
*
|
|
1614
|
-
* const combined = concat(basicTuple, serverTuple);
|
|
1615
|
-
* // Type: Parser<[boolean, number, string, boolean], [BasicState, ServerState]>
|
|
1091
|
+
* Merges multiple object-like parsers into one parser.
|
|
1616
1092
|
*
|
|
1617
|
-
*
|
|
1618
|
-
*
|
|
1619
|
-
*
|
|
1620
|
-
*
|
|
1621
|
-
* @template TA The value type of the first tuple parser.
|
|
1622
|
-
* @template TB The value type of the second tuple parser.
|
|
1623
|
-
* @template TStateA The state type of the first tuple parser.
|
|
1624
|
-
* @template TStateB The state type of the second tuple parser.
|
|
1625
|
-
* @param a The first {@link tuple} parser to concatenate.
|
|
1626
|
-
* @param b The second {@link tuple} parser to concatenate.
|
|
1627
|
-
* @return A new {@link tuple} parser that combines the values of both parsers
|
|
1628
|
-
* into a single flattened tuple.
|
|
1629
|
-
* @since 0.2.0
|
|
1093
|
+
* @param parsers Parsers to merge in declaration order.
|
|
1094
|
+
* @returns A parser that merges parsed object fields from all parsers.
|
|
1095
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
1096
|
+
* @since 0.4.0
|
|
1630
1097
|
*/
|
|
1631
|
-
declare function
|
|
1098
|
+
declare function merge<const TParsers extends MergeParsers>(...parsers: EnsureMergeParsers<TParsers> & MergeArityGuard<TParsers>): MergeReturnType<TParsers>;
|
|
1632
1099
|
/**
|
|
1633
|
-
*
|
|
1634
|
-
* a flattened tuple containing the values from all parsers in order.
|
|
1100
|
+
* Merges multiple object-like parsers into one parser, with options.
|
|
1635
1101
|
*
|
|
1636
|
-
* @
|
|
1637
|
-
* @
|
|
1638
|
-
*
|
|
1639
|
-
* @
|
|
1640
|
-
* @template TStateB The state type of the second tuple parser.
|
|
1641
|
-
* @template TStateC The state type of the third tuple parser.
|
|
1642
|
-
* @param a The first {@link tuple} parser to concatenate.
|
|
1643
|
-
* @param b The second {@link tuple} parser to concatenate.
|
|
1644
|
-
* @param c The third {@link tuple} parser to concatenate.
|
|
1645
|
-
* @return A new {@link tuple} parser that combines the values of all parsers
|
|
1646
|
-
* into a single flattened tuple.
|
|
1647
|
-
* @since 0.2.0
|
|
1102
|
+
* @param rest Parsers to merge, followed by merge options.
|
|
1103
|
+
* @returns A parser that merges parsed object fields from all parsers.
|
|
1104
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
1105
|
+
* @since 0.7.0
|
|
1648
1106
|
*/
|
|
1649
|
-
declare function
|
|
1107
|
+
declare function merge<const TParsers extends MergeParsers>(...rest: [...parsers: EnsureMergeParsers<TParsers>, options: MergeTailOptions] & MergeArityGuard<TParsers>): MergeReturnType<TParsers>;
|
|
1650
1108
|
/**
|
|
1651
|
-
*
|
|
1652
|
-
* a flattened tuple containing the values from all parsers in order.
|
|
1109
|
+
* Merges multiple object-like parsers into one labeled parser.
|
|
1653
1110
|
*
|
|
1654
|
-
* @
|
|
1655
|
-
* @
|
|
1656
|
-
* @
|
|
1657
|
-
*
|
|
1658
|
-
* @
|
|
1659
|
-
* @template TStateB The state type of the second tuple parser.
|
|
1660
|
-
* @template TStateC The state type of the third tuple parser.
|
|
1661
|
-
* @template TStateD The state type of the fourth tuple parser.
|
|
1662
|
-
* @param a The first {@link tuple} parser to concatenate.
|
|
1663
|
-
* @param b The second {@link tuple} parser to concatenate.
|
|
1664
|
-
* @param c The third {@link tuple} parser to concatenate.
|
|
1665
|
-
* @param d The fourth {@link tuple} parser to concatenate.
|
|
1666
|
-
* @return A new {@link tuple} parser that combines the values of all parsers
|
|
1667
|
-
* into a single flattened tuple.
|
|
1668
|
-
* @since 0.2.0
|
|
1111
|
+
* @param label Label used in documentation output.
|
|
1112
|
+
* @param parsers Parsers to merge in declaration order.
|
|
1113
|
+
* @returns A parser that merges parsed object fields from all parsers.
|
|
1114
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
1115
|
+
* @since 0.4.0
|
|
1669
1116
|
*/
|
|
1670
|
-
declare function
|
|
1117
|
+
declare function merge<const TParsers extends MergeParsers>(label: string, ...parsers: EnsureMergeParsers<TParsers> & MergeArityGuard<TParsers>): MergeReturnType<TParsers>;
|
|
1118
|
+
type ConcatParserArity = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15;
|
|
1119
|
+
type ConcatArityLimitError = {
|
|
1120
|
+
readonly __optiqueConcatArityLimit: "concat() requires between 1 and 15 parser arguments. Nest concat() to combine more.";
|
|
1121
|
+
};
|
|
1122
|
+
type ConcatParsers = readonly Parser<Mode, readonly unknown[], unknown>[];
|
|
1123
|
+
type ConcatArityGuard<TParsers extends readonly unknown[]> = IsTuple<TParsers> extends true ? TParsers["length"] extends ConcatParserArity ? unknown : ConcatArityLimitError : unknown;
|
|
1124
|
+
type ConcatStates<TParsers extends ConcatParsers> = { [K in keyof TParsers]: TParsers[K] extends Parser<Mode, readonly unknown[], infer TState> ? TState : never };
|
|
1125
|
+
type ConcatTupleValues<TParsers extends ConcatParsers> = TParsers extends readonly [Parser<Mode, infer THead extends readonly unknown[], unknown>, ...infer TRest extends ConcatParsers] ? [...THead, ...ConcatTupleValues<TRest>] : [];
|
|
1126
|
+
type ConcatValues<TParsers extends ConcatParsers> = IsTuple<TParsers> extends true ? ConcatTupleValues<TParsers> : readonly unknown[];
|
|
1671
1127
|
/**
|
|
1672
|
-
* Concatenates
|
|
1673
|
-
* a flattened tuple containing the values from all parsers in order.
|
|
1128
|
+
* Concatenates tuple parsers into one parser with a flattened tuple value.
|
|
1674
1129
|
*
|
|
1675
|
-
* @
|
|
1676
|
-
* @
|
|
1677
|
-
*
|
|
1678
|
-
* @template TD The value type of the fourth tuple parser.
|
|
1679
|
-
* @template TE The value type of the fifth tuple parser.
|
|
1680
|
-
* @template TStateA The state type of the first tuple parser.
|
|
1681
|
-
* @template TStateB The state type of the second tuple parser.
|
|
1682
|
-
* @template TStateC The state type of the third tuple parser.
|
|
1683
|
-
* @template TStateD The state type of the fourth tuple parser.
|
|
1684
|
-
* @template TStateE The state type of the fifth tuple parser.
|
|
1685
|
-
* @param a The first {@link tuple} parser to concatenate.
|
|
1686
|
-
* @param b The second {@link tuple} parser to concatenate.
|
|
1687
|
-
* @param c The third {@link tuple} parser to concatenate.
|
|
1688
|
-
* @param d The fourth {@link tuple} parser to concatenate.
|
|
1689
|
-
* @param e The fifth {@link tuple} parser to concatenate.
|
|
1690
|
-
* @return A new {@link tuple} parser that combines the values of all parsers
|
|
1691
|
-
* into a single flattened tuple.
|
|
1130
|
+
* @param parsers Tuple parsers to concatenate.
|
|
1131
|
+
* @returns A parser with flattened tuple values from all parsers.
|
|
1132
|
+
* Type inference is precise for tuple calls up to 15 parser arguments.
|
|
1692
1133
|
* @since 0.2.0
|
|
1693
1134
|
*/
|
|
1694
|
-
declare function concat<
|
|
1135
|
+
declare function concat<const TParsers extends ConcatParsers>(...parsers: TParsers & ConcatArityGuard<TParsers>): Parser<CombineModes<{ readonly [K in keyof TParsers]: ExtractMode<TParsers[K]> }>, ConcatValues<TParsers>, ConcatStates<TParsers>>;
|
|
1695
1136
|
/**
|
|
1696
1137
|
* Wraps a parser with a group label for documentation purposes.
|
|
1697
1138
|
*
|