Remix.run Logo
krig 6 days ago

Is that really the whole reason for this grudge? He gave you a bunch of comments to work from! I was expecting a lot less from your description.

I don't find it too hard to figure out what he meant - he doesn't want to you change the case style of procedure calls, but he _does_ want you to remove redundant namespacing as in the CURL prefix.

Maybe you could have looked at some other vendored libraries to see how they handled things like constant naming and other formatting?

johnisgood 6 days ago | parent [-]

I posted the link and now the PR is getting filled with comments. Lord. This is why I did not want to look for and post the link to begin with!

Some guy did ask questions I would have asked, at least.

Back to the CURL prefix, what is wrong with it? It is how it is in curl.h and without it, it looks kind of meh. What would the "CURL" distinct type be without the CURL prefix? :P

I hope I did not make a mess just by posting the URL. I will remove it. I do not need more (supposedly trolls) in there and make more of a big fuss than I did on here.

thegeekpirate 6 days ago | parent [-]

> Back to the CURL prefix, what is wrong with it?

It prevents stuttering when using it `curl.CURL_*`.

> What would the "CURL" distinct type be without the CURL prefix?

`CURL` isn't a prefix there.

Take more time to think things through.

johnisgood 6 days ago | parent [-]

I did, thank you. Please explain why would anyone (end user of library) ever want "curl.CURL_GLOBAL_ALL", for example? If anything, it should be private. If you really want to go there, sure. I think it is YOU who should think things through. I get that you are filled with hatred, but come on man. Think. Why would anyone want to call "curl.CURL_GLOBAL_ALL" from a binding which is supposed to be used as a high-level curl library? If it is possible (I have no idea) to make it private, then it should be made private. It is not intended to be used by the users of the library, is it? The higher level functions are the ones supposed to be used by them, and they seem to be named correctly from a quick glance.

If you reply, do so without ad hominems and with some respect. Thank you.

thegeekpirate 6 days ago | parent [-]

Last question I'll answer, because you aren't doing any of this is good faith.

You mean `curl.GLOBAL_ALL`, and it's for https://curl.se/libcurl/c/curl_global_init.html

johnisgood 6 days ago | parent [-]

  // CURL_GLOBAL_ALL combines all initialization flags.
  CURL_GLOBAL_ALL: i64 = 3
It has nothing to do with "curl_global_init()". This - which is a high-level function intended to be called by the users of the library - has:

  init :: proc() -> (ok: bool) {
    return curl_global_init(CURL_GLOBAL_ALL) == 0
  }
As you can see, higher-level function calls low-level function. The higher-level function does not have "curl" as the prefix.

My question still stands and has not been answered.