toc

Cogent chimeras compelling chastised computing

2021-04-17, post № 243

poem, #doubt

Insightful sparks, a forceful nudge —
distant glory or arcane mist:
now wobbly treading trodden paths,
sensing tender sprawling fates …
A step is taken.
A step is taken to one’s side.
Lured in by wonderous ideals,
a gate is shut, the key expunged.
But is what one seeks on this flank to be found?
Or has one only shown themselves:
what one wants most do not;
since never urged to do inquire
about attaining what they never
have proven to be all they could accept?
Away with all the doubt!
One tightly clings to specks deemed fit.
It cannot, must not, dare not crumble!
The flimsy veil begins to lift.
What now? Where to? Once one has sipped?
Stuck in between, not free, not flocking.
Gazing through bars into the veldt
whose sparse and slanted Terminaliae
crash down, they too reveil a fence.

— Jonathan Frech, April of 2021

A source location identification regression in GHC triggered by seven bytes

2021-03-22, post № 242

haskell, compiler-bug, #ghc, #parsing

Working on a minimal XML parser which does both build a data structure and remember its nodes’ source origin, I discarded the second part of a two-tuple by not requiring anything to be present. Yet instead of informing me that a mapping cannot be deconstructed, GHC 8.10.4 gave me an obscure error message:

% runhaskell Xml.hs

<no location info>: error: Tuple section in pattern context

Thankfully I sometimes adhere to a mindfully incremental approach and was not as bewilderingly disoriented as I could have been — after all, a there is an error message possesses little more value than solely stating an executable cannot be built.

Inspecting the probable location I had intelligence on, I managed to extract a seven long byte sequence which triggers a <no location info> compilation error:

j(0,)=0

Yet compilers are squeamish and shapeshifting entities — especially with regards to diagnostic capabilities. Whilst j(0,)=0 cannot be traced, j(,0)=0 induces the expected and appropriate error. As such, I tested the phenomenon using varying GHC versions:

% ghc --version && printf '%s' 'j(0,)=0' > /tmp/nli.hs && ghc /tmp/nli.hs 2>&1 \
cmdand cmdand>     | grep -q '<no location info>' ; echo $?
The Glorious Glasgow Haskell Compilation System, version 8.10.4
0
% ghc --version && printf '%s' 'j(0,)=0' > /tmp/nli.hs && ghc /tmp/nli.hs 2>&1 \
cmdand cmdand>     | grep -q '<no location info>' ; echo $?
The Glorious Glasgow Haskell Compilation System, version 8.8.4
1

To my surprise, I seemed to have found a GHC regression — triggered by only seven bytes.

Alas, this regression is a known one: Another <no location info> error (Tuple section in pattern context) has been opened on the 8th of March 2021, with its comments identifying it as a regression. Yet the fix outlined and performed is as much resolving an aspect of the issue as is it making a stylistic decision — myself facing the same problem of source location corseness, I am leaning further and further towards the approach of less pedantically accurate reporting allowing for a more minimal implementation.

Intriguingly Matured Graphics

2021-03-20, post № 241

imagery, Pygame, #throwback, #png, #colorful

Following digital excavation efforts at my disk’s deep directories, I stumbled upon a collection of colorful pseudo-random walk graphics. Since they are dated September of 2015 and were generated using unidiomatic slow snake script, their only property of note is a visually jolly aura; the following three possess a particularly vibrant one:

intriguingly-matured-graphics_2015-09-24_fancy-12.png
Autumn Colors
intriguingly-matured-graphics_2015-09-25_fancy-24.png
Deep Blue
intriguingly-matured-graphics_2015-09-27_fancy-29.png
Woven Violet
Jonathan Frech's blog; built 2021/04/16 21:21:49 CEST