Slow slow progress! I'm in the middle of a sequence of marketing improvement courses (CompTIA A+, Network+, ITIL, Windows 7, and Windows Server 2003/2008), so the progress at sternons mkmap is proceeding very slowly. I like learning courses, so there's no real trouble, but I also would like to develop my private astronomy book plans requiring star maps, and similar. Maybe also I'll be lucky enough to get a job that contains a little C programming beside the PC-administration or networking jobs I'm preparing for.
The releases r118 to r120 slowly continued the novel dynamical object system produced by "carving plaster" – let's call it the plaster object system – but then I realized how tedious it is lacking string literals for pure 32 bit int wide strings.
Lacking those, I hacked a converter (neither a parser nor scanner – more like an oversimplistic preprocessor) that scans a file, collects strings with the syntax u"example string"
perusing
an initial nonstandard u"
as a string marker for my own string literals. Now the function ustring_to_attrib
in file pointobj.uc
is converted as follows
source pointobj.uc | target pointobj.c |
---|---|
int ustring_to_attrib(uchar *ustr) { |
int ustring_to_attrib(uchar *ustr) { |
All such 32 bits wide string constants are then collected into the file allstrings.h
, containing (among others):
static uchar _UC_R_2E_A_2E_[] = {'R','.','A','.',0}; /* R.A. */ static uchar _UC_RA[] = {'R','A',0}; /* RA */ static uchar _UC__3B1_[] = {0x3B1,0}; /* α */
The releases in chronorder:
- R118 (May 25, 2011): "More plaster carving towards dynamical classes" experimental refactorings directed from static defines to dynamic allocation
- R119 (Jun 13, 2011): "In the middle of refactoring" more mature refactorings in the same direction
- R120 (Jun 13, 2011): "More object class refactorings" more refactorings – removing a conceptual flaw: the object type identifier must (!) be stored at the same position in all objects, minor other code fixes
- R121 (Jul 22, 2011): "Further walking around Windows wide C-string limitations" novel invention – half-way wide string literal converter implemented: demo conversion seems OK
- R122 (Aug 1, 2011): "String literal converter - ucliterals" the above wide string literal converter implemented and perused in code generation
No comments:
Post a Comment