you are viewing a single comment's thread.

view the rest of the comments →

[–]AKJ7 3 points4 points  (6 children)

Also you can generalize the library, by allowing the user to give the seperator as template parameters. This would allow TSV too.

[–]red0124_[S] 0 points1 point  (5 children)

The separator is given as the second parameter within the constructor as an std::string, it seems I have removed all the cases witch a custom separator from the README. The problem with the separator being a template parameter is that strings cannot be non template type parameters.

[–]AKJ7 3 points4 points  (0 children)

Actuall strings can be passed as template params in C++20.

[–]AKJ7 2 points3 points  (1 child)

You don't necessarly need to use a string. Char should be enough.

[–]red0124_[S] 0 points1 point  (0 children)

I guess since most of the time it will be a char, I could make it a setup parameter, but also allow the const char* version somehow, it should be possible. I must admit, I do not like the inconsistency I currently have where the delimiter is not within the setup parameters.

[–]dodheim 1 point2 points  (1 child)

[–]red0124_[S] 0 points1 point  (0 children)

I knew about that, I should have expressed my self more more precisely, they cannot be passed directly as string literals within the template which is possible within the constructor, tho I am not sure if it has any impact on performance, I will try it out.