Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing some information about the differences between v2 and v3 #58

Open
claudix opened this issue Dec 11, 2020 · 1 comment
Open

Missing some information about the differences between v2 and v3 #58

claudix opened this issue Dec 11, 2020 · 1 comment
Assignees

Comments

@claudix
Copy link

claudix commented Dec 11, 2020

I've been using argtable2 for a very long time and recently I've came across with this project. It'd be nice to clarify some points in the docs:

  • What are the differences between v3 and v2 so that they are incompatible?
  • Is the library thread-safe? (I guessed that it's not, since it uses non-thread-safe functions such as getopt()

The amalgamation feature is a +1 feature, so thanks for that!

@tomghuang
Copy link
Contributor

Hi @claudix ,

From users' point of view, the major differences are:

  • Change to 3-Clause BSD license.
  • Provide amalgamation distribution.
  • Add APIs to support subcommands.
  • Add APIs to manage dynamic strings and make it easier to write Tcl commands.

I believe you can still use most of the v2 APIs in v3. However, v3 doesn't promise to be compatible with v2, so I can have more freedom to shape v3 APIs.

v3 is still based on getopt, so you're right, maybe it is not thread-safe. However, I never use Argtable3 in multi-thread scenarios, so I never think about making v3 a thread-safe library. If there's such a use case, maybe we can dedicate a thread to Argtable3, and all the other threads can call the service exposed by the Argtable3 thread to parse commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants