Programming Leftovers
-
Rlang ☛ Comparison of spatial patterns in categorical raster data for arbitrary regions using R
This is the fifth part of a blog post series on comparing spatial patterns in raster data. More information about the whole series can be found in part one.
This blog post focuses on comparing spatial patterns in categorical raster data for arbitrary regions. This means that the methods shown can be applied to compare rasters of the same region (for example, with the same resolution) and rasters of different regions (extents), resolutions, etc. This implies that the outcome of such comparisons is a single value, which indicates the difference/similarity between the spatial patterns of the two rasters.
-
Rlang ☛ Calculating at Pencil and Paper Scale
Introduction It can be fun to drive a problem all the way into the ground. I don’t always get to do that on paying projects, however sometimes I can do it with hobby projects.
-
MaskRay ☛ Keeping pace with LLVM: compatibility strategies
LLVM's C++ API doesn't offer a stability guarantee. This means function signatures can change or be removed between versions, forcing projects to adapt.
On the other hand, LLVM has an extensive API surface. When a library like llvm/lib/Y relies functionality from another library, the API is often exported in header files under llvm/include/llvm/X/, even if it is not intended to be user-facing.
To be compatible with multiple LLVM versions, many projects rely on #if directives based on the LLVM_VERSION_MAJOR macro. This post explores the specific techniques used by ccls to ensure compatibility with LLVM versions 7 to 19.
-
University of Toronto ☛ Maybe skipping 'Dependabot' commits when using 'git log'
As someone who reads the commit logs of these repositories to stay on top of significant changes, these Dependabot dependency version bumps are uninteresting to me and, like any noise, they make it harder to see what I'm interested in (and more likely that I'll accidentally miss a commit I want to read about that's stuck between two Dependabot updates I'm skipping with my eyes glazed over). What I'd like to be able to do is to exclude these commits from what 'git log' or some equivalent is showing me.
-
[Old] ACM ☛ The Emperor's Old Clothes
The author recounts his experiences in the implementation, design, and standardization of computer programming languages, and issues a warning for the future.
-
Craft Of Coding ☛ Algol-68 seemed like a good idea – until it wasn’t
The 1960s saw rapid growth in programming languages, which was both good and bad. The first (commercial) languages appeared in the late 1950s, in the guise of Fortran, and Cobol, which were very successful. Work on Algol started in 1958, it was to be a scientific programming language, providing features that Fortran just didn’t, e.g. better structured control, in a package that had roughly the same scope as Fortran, i.e. numerical computation. Algol-58 didn’t really get too far, with emphasis shifting to Algol-60 first implemented by 1960. Algol-60 had a lot going for it, but it seemingly wasn’t enough for the group that produced the 1962 revision of Algol-60. Working Group 2.1 of IFIP wanted a more universal language, one whose scope could include areas covered by Cobol and Lisp, and so they set about extending the language into Algol-X, what would become Algol-68. But Algol-68 wasn’t really a new version of Algol, it was a whole new language. A very complex, and intriguing language, perhaps ahead of its time, perhaps too obscure.
-
[Old] Computer History Museum ☛ Revised Report on the Algorithmic Language Algol 68 [PDF]
Since the publication of the Original Report, much discussion has taken place in the Working Group concerning the further development of the language. This has been influenced by the experience of many people who saw disadvantages in the original proposals and suggested revised or extended features. Amongst these must be mentioned especially: I.R. Currie, Susan G. Bond, J.D. Morison and D. Jenkins of Malvern (see in [17]), in whose dialect of ALGOL 68 many features of this Revision may already be found; P. Branquart, J.P. Cardinael and J. Lewi of Brussels, who exposed many weaknesses (see in [17]); Ursula Hill, H. Woessner and H. Scheidig of Munich, who discovered some unpleasant consequences; the contributors to the Rapport d"Evaluation I 19); and the many people who served on the Working Group subcommittees on Maintenance and Improvements (convened by M. Sintzoff) and on Transput (convened by C.H. Lindsey). During the later stages of the revision, much helpful advice was given by H. Boom of Edmonton, W. Freeman of York, W.J. Hansen of Vancouver, Mary Zosel of Livermore, N. Yoneda of Tokyo, M. Rain of Trondheim, L. Ammeraal, D. Grune, H. van Vliet and R. van Vliet of Amsterdam, G. van der Mey of Delft, ~nd A.A. Baehrs and A.F. Rar of Novosibirsk. The editors of this revision also wish to acknowledge that the wholehearted cooperation, support, interest, criticism and violent objections on the part of the members of WG 2.1 have continued unabated during this time.
-
Jonathan Dowland ☛ Jonathan Dowland: Progressively enhancing CGI apps with htmx
I was interested in learning about htmx, so I used it to improve the experience of posting comments on my blog.
It seems much of modern web development is structured around having a JavaScript program on the front-end (browser) which exchanges data encoded in JSON asynchronously with the back-end servers. htmx uses a novel (or throwback) approach: it asynchronously fetches snippets of HTML from the back-end, and splices the results into the live page. For example, a htmx-powered button may request a URI on the server, receive HTML in response, and then the button itself would be replaced by the resulting HTML, within the page.
-
Perl / Raku
-
Arne Sommer ☛ Next Consecutive with Raku
Write a script to return the length of the longest consecutive elements sequence. Return -1 if none found. The algorithm must runs in O(n) time.
-