Programming Leftovers
-
Spidermonkey Development Blog: SpiderMonkey Byte-Sized Architectures
I recently presented on SpiderMonkey and Byte-Sized Architectures at a JSConf.jp/TC39 collaborative meeting the evening before the TC39 plenary in Tokyo. The first part of the presentation is a high-level view of the overall architecture of SpiderMonkey, and gives an idea of how a modern JavaScript engine is put together. In the second part, I talk about bytesize architectures a way for teams to build a shared understanding of complicated systems.
-
What is Polyglot (and Hyperpolyglot) in Programming
A traditional journey for non-programmers entering the programming realm is to choose one of many programming languages and begin mastering it until they are able to make some use of it and create a full-fledged application.
-
Bruce Schneier ☛ Leaving Authentication Credentials in Public Code
Interesting article about a surprisingly common vulnerability: programmers leaving authentication credentials and other secrets in publicly accessible software code:
Researchers from security firm GitGuardian this week reported finding almost 4,000 unique secrets stashed inside a total of 450,000 projects submitted to PyPI, the official code repository for the Python programming language. Nearly 3,000 projects contained at least one unique secret. Many secrets were leaked more than once, bringing the total number of exposed secrets to almost 57,000...
-
Simon Ser ☛ Simon Ser: Status update, November 2023
Hi! This month I’ve started a new PotM called pyonji. It’s an easy-to-use replacement for the venerable
git-send-email
command. The goal is to make it less painful for a new contributor not familiar with the e-mail based patch submission to submit patches.[...]
Then pyonji will present a UI with a list of commits to be submitted for review. The user can tweak details such as the base branch, the mailing list address, the version of the patch, however that’s rarely needed: pyonji will find good defaults for these. The user can add a cover letter if desired with a longer description for the set of patches. Then the big blue “submit” button can be pressed to send the patches.
Unlike git-send-email, pyonji will remember for you what the last submitted version number was (and automatically increment it). pyonji will save the cover letter so that it’s not lost if the network is flaky and you don’t need to re-type it for the next submission. pyonji will not waste your time with uninteresting questions such as “which encoding should I use?”. pyonji will automatically include the base tree information in the patches so that any conflicts are more easily resolved by the reviewer.
-
Adriaan de Groot ☛ C++23 Characters
C++ is definitely a language that has Lots of Ways to do It – kind of like Perl’s TIMTOWTSAC. UTF-8 is a suitable source encoding for C++ source, so that you can write string literals in UTF-8. Convenient for adding a poop emoji to an error message, or if your application is very local and doesn’t need translations.
A tiny example (which I have not bothered compiling, YMMV): [...]
-
Andy Wingo: a whiff of whiffle
A couple nights ago I wrote about a superfluous Scheme implementation and promised to move on from sheepishly justifying my egregious behavior in my next note, and finally mention some results from this experiment. Well, no: I am back on my bullshit. Tonight I write about a couple of implementation details that discerning readers may find of interest: value representation, the tail call issue, and the standard library.
what is a value?
As a Lisp, Scheme is one of the early "dynamically typed" languages. These days when you say "type", people immediately think propositions as types, mechanized proof of program properties, and so on. But "type" has another denotation which is all about values and almost not at all about terms: one might say that vector-ref has a type, but it's not part of a proof; it's just that if you try to vector-ref a pair instead of a vector, you get a run-time error. You can imagine values as being associated with type tags: annotations that can be inspected at run-time for, for example, the sort of error that vector-ref will throw if you call it on a pair.
Scheme systems usually have a finite set of type tags: there are fixnums, booleans, strings, pairs, symbols, and such, and they all have their own tag. Even a Scheme system that provides facilities for defining new disjoint types (define-record-type et al) will implement these via a secondary type tag layer: for example that all record instances are have the same primary tag, and that you have to retrieve their record type descriptor to discriminate instances of different record types.
Anyway. In Whiffle there are immediate types and heap types. All values have a low-bit tag which is zero for heap objects and nonzero for immediates. For heap objects, the first word of the heap object has tagging in the low byte as well. The 3-bit heap tag for pairs is chosen so that pairs can just be two words, with no header word.
-
R
-
Rlang ☛ Highlights from R-Ladies Paris Hybrid Meetup Empowering Community Outreach
This blog post contributed by Mouna Belaid, on behalf of the R-Ladies Paris team We were delighted to host a recent hybrid event called Feedback from Experiences in Data Science...
-
Rlang ☛ The Fast and the Curious: Optimizing R
The Need for Speed in RIn the realm of data science, where the landscape is ever-changing and data volumes are incessantly swelling, speed and efficiency in processing aren’t mere conveniences — they’re indispensable.
-
Rlang ☛ Efficient row min calculation: From R to C
My colleague Chung-hong Chan started a new package in our teams Microsoft's proprietary prison GitHub organization. An issue there caught my attention.
-
-
Python
-
How to Execute Javascript in a Jupyter Notebook on Linux
Jupyter Notebook is the most popular server-client application that allows you to write, run, test, and debug Python-interpreted programs on notebook documents via a web browser. Unfortunately, other interpreted programming languages, such as Javascript, lack such fully-fledged applications that offer tight integration and enable users
-