4 ms·
A large part of learning the language is learning the API. Is it possible to build a single common API ?
by petra 10y ago
A large part of learning the language is learning the API. Is it possible to build a single common API ?
- cakebrewery 10y agoThe reason why some languages are more suited for some things than others is due to paradigms like callbacks in JS that were fit to certain applications (the web in this case). Python is incorporating newer "paradigms" like asyncio into its language, but it feels convoluted at this point. The preference of certain semantics for different application types brings forth the same problem (convolution) if we tried to implement a single API that fits all purposes.
- shriramkmurthi 10y agoNo. I think the best illustration is the continuation-based Web programming work we did several years ago: http://cs.brown.edu/~sk/Publications/Papers/Published/khmgpf-impl-use-plt-web-server-journal/ http://cs.brown.edu/~sk/Publications/Papers/Published/khmgpf... If you don't have the right underlying language (in this case, with continuations), you _can't_ have a similar API. Similarly, the reactive APIs we had in Flapjax [http://cs.brown.edu/~sk/Publications/Papers/Published/mgbcgbk-flapjax/ http://cs.brown.edu/~sk/Publications/Papers/Published/mgbcgb...] enabled entirely new kinds of primitive “library” operations; see, for instance, the drag-and-drop example in that paper.
- themihai 10y agoAt most you can have similar name conventions (e.g. strings.Contains, or Replace etc) but even so some languages use camelCase others dashes etc