Named parameters#2
Conversation
|
I am looking at this right now, thanks! |
|
I am using default MSVC 2013 and its implementation of C++11 doesn't support Also, it would be better if the parameters loose the preceding underscore, so: This is a great addition to the code, @dtmoodie |
|
Thanks, I can look into MSVC2013. I believe most of it can be done without constexpr, it'll just require a bit of tweaking. |
|
The reason I am inclined to push "naked" param names is to match what matplotlib offers for Python. |
…used to place them in a separate namespace if the user doesn't want them in the global namespace. removed the requirement for constexpr.
|
I think this should be a good solution, there is a define PLT_ARG_NAMESPACE which can be used to place named parameters into a namespace but by default they are globally accessible. It should also work on MSVC2013 because I compiled without constexpr on 2015. It'll be a bit until 2013 finishes downloading for me to test it there though. |
|
Ok, I'm gonna give you time to test with MSVC 2013. |
|
Hmm.. it compiled without problems. NICE!
Do you think you can fix it? If you are short on time I can do all that. But if I download the code and do it, you will miss a merge on Github. I can fix this by adding a Contributors.txt to the repository with your name on it. |
|
No worries I can fix it up in the next few hours. |
|
Let me know when you are done. Sometimes this page confuses me. |
|
Ok I think it should be good now. All the unit tests look the same as on your main page and I removed the .pro.user file. Something to consider for is I currently have parameter inference disabled. It would be possible to have specific parameters inferred by their type. IE if you pass in just one QString and you enable inference on the marker tag, then that QString is assumed to be marker. Currently it is entirely disabled. |
Initial implementation, debugging test8. Check it out and tell me what you think.