boostorg / boostorg/program_options

[Feature] Allow Unknown Options from all sources

未关闭
#83 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
C++
星标
136
派生
117
PR 合并指标
30 天内没有已合并 PR

描述

For the command line parser, there is the [`allow_unregistered()` method](https://www.boost.org/doc/libs/1_70_0/doc/html/program_options/howto.html#id-1.3.32.6.9) to not throw an exception whenever an option is not recognized.

However, this is missing from the configuration file and environment parsers.

It is possible to do work around this for both [configuration files](https://stackoverflow.com/questions/23664503/parsing-unregistered-options-for-config-files-in-boost-program-options) and [environment](https://stackoverflow.com/questions/53285248/boost-program-options-allow-undeclared-from-environment), but I am of the opinion this should be handled in similar fashion to the command line parsers!

贡献指南

这个仓库没有索引到贡献指南

调研方向

先从命令行解析中已记录的 allow_unregistered() 行为开始,然后比较配置文件解析器和环境解析器如何处理未知选项。在决定现有解析器应如何行为之前,先查看链接的配置和环境变通方案。完成的标准是:三个来源中的未知选项都能以一致的方式处理,且没有例外。

由索引模型根据 Issue 内容生成。

评估

技术栈
cpp
领域
cli
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
42/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。