I suspect, in concept, it is closer to engineering, but likely, in terms of the actual experience and similar, is probably more similar to writing.
actually, I think it is more like reading or writing, but more directly tied into visual processing and thinking, rather than natural language which more often is tangled up with and has to take a route through auditory thinking processes.
I think it may actually be a little easier, as I have more "mental bandwidth" in the visual space than in the auditory space, which can often only really manipulate information about as fast as it can be heard or played back.
but, at least for me, the auditory route is more directly linked to semantics and "meaning", leading more often to code being handled in terms of visual manipulations, with some overlap with my sense of tactile experience (almost like if a person had extra arms which were able to quickly manipulate the thoughts within ones' head). sort of like where any thinking and associated mental and physical actions all sort of end up tangled together.
so, it gets confusing how it is best classified...
and, "the experience of endlessly manipulating bits of text in an editor and similarly manipulating bits of text in editors with ones' mind, often at several times the speed they can manipulate the text IRL, and typing out the bits of code which form within ones' mind" would be a woefully inadequate description...
nevermind if one claims that representations of data-structures seem to have a size/shape/feel almost like they were physically existent objects, where working with code and data-structures is an experience almost like messing with something like legos or similar (like, where the programmer can actually "feel" the code, which in some ways isn't just like flat text, but is in some ways almost like its own independent entity, which almost seems to quietly speak about what it wants to be and what it wants to be able to do, ...).
yeah, weird and meta I know.
so, I don't really know how it fits, if closer to writing or engineering, or how exactly writers and engineers seem to experience things.
I am aware though that when trying to write fiction, it is often an experience more like I am sitting around watching something happen on TV, and then describing what it is I am seeing, with some ability to "imagine" things which happen or are pulled into the scene (or to try to steer the action), which then influence what starts to happen (how the characters respond, etc...), then I basically pause/unpause or cause it to advance at a slower rate to give more of a chance to write about and describe what I am seeing (and don't often know how things will start to turn out before I start writing about them). but, at the same time, one also can sort of know the thoughts and feelings of all the characters in the scene, which in turn determine how they respond to the various events and actions by other characters, ...
but, I guess it is sort of similar.
I have sometimes found that I am slightly limited by what sorts of things I can imagine, like if I can't visualize an object or thing in space, I can't really describe or reason about it.
like, logic and math becomes like a physical mechanism, with the "shape" of the mechanism, interconnections of various parts, basically influencing how things "fall through" the device, ...
this gets to be a problem with more advanced math though, as things seem to go into areas which are harder to visualize or reason about as objects.
but, with a machine, one can imagine the device and its parts doing their things, and have a pretty good idea how it will behave, or just imagine the device from the known parts and "poke at it" and see what happens and similar.
or, you can pull a person (or big robot or whatever else) into the scene and they can poke at the device, or throw a stream or rocks at something, or whatever else.
(yet I still fail to make good game contents or think up much interesting to make happen in it...).
or such...