Repository navigation
Expand file tree
/
Copy pathgnustep-libs-corebase-webkit-gaps.html
More file actions
1601 lines (1432 loc) · 64.6 KB
/
Copy pathgnustep-libs-corebase-webkit-gaps.html
File metadata and controls
1601 lines (1432 loc) · 64.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>libs-corebase — CoreFoundation gaps for WebKit</title>
<style>
:root {
--bg: #fbfbf8;
--fg: #1a1a1a;
--muted: #555;
--accent: #b03000;
--accent2: #0a4d68;
--ok: #1f7a1f;
--warn: #b06800;
--bad: #b00020;
--code-bg: #f0ece4;
--rule: #d6cfc0;
--card: #fff;
}
html { -webkit-text-size-adjust: 100%; }
body { margin: 0 auto; max-width: 1080px; padding: 2.5rem 1.5rem 6rem;
font: 16px/1.55 -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
color: var(--fg); background: var(--bg); }
h1 { font-size: 2rem; line-height: 1.2; margin: 0 0 .25rem; }
h2 { font-size: 1.4rem; margin: 2.5rem 0 .75rem; padding-bottom: .25rem; border-bottom: 2px solid var(--rule); }
h3 { font-size: 1.15rem; margin: 1.75rem 0 .5rem; color: var(--accent2); }
h4 { margin: 1.25rem 0 .35rem; }
.subtitle { color: var(--muted); font-size: 1.05rem; margin: 0 0 2rem; }
code, pre, kbd { font-family: "SF Mono", Menlo, Consolas, monospace; }
code { background: var(--code-bg); padding: 1px 5px; border-radius: 3px; font-size: .9em; }
pre { background: var(--code-bg); padding: .85rem 1rem; border-radius: 6px;
overflow-x: auto; font-size: .82rem; line-height: 1.45;
border-left: 3px solid var(--accent2); }
pre code { background: none; padding: 0; }
pre.shell { border-left-color: var(--ok); }
pre.objc { border-left-color: var(--accent); }
a { color: var(--accent2); }
a:hover { color: var(--accent); }
.tldr { background: var(--card); border: 1px solid var(--rule); border-left: 4px solid var(--accent2);
padding: 1rem 1.25rem; border-radius: 6px; margin-bottom: 2rem; }
.tldr h3 { margin-top: 0; color: var(--accent2); }
.pill { display: inline-block; font-size: .72rem; padding: 1px 8px; border-radius: 999px;
background: #eee; color: #333; margin-left: .35rem; vertical-align: middle;
font-weight: 600; letter-spacing: .02em; }
.pill.ok { background: #d8efd8; color: var(--ok); }
.pill.warn { background: #f6e4cb; color: var(--warn); }
.pill.bad { background: #f5d0d6; color: var(--bad); }
.pill.info { background: #d6e6f3; color: var(--accent2); }
table { border-collapse: collapse; width: 100%; margin: 1rem 0; font-size: .92rem; }
th, td { text-align: left; padding: .5rem .65rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { background: #eee5d6; }
tr:nth-child(even) td { background: #faf6ed; }
table.compact td, table.compact th { padding: .35rem .55rem; font-size: .88rem; }
.nav { position: sticky; top: 0; background: var(--bg); margin: -2.5rem -1.5rem 2rem;
padding: .75rem 1.5rem; border-bottom: 1px solid var(--rule);
font-size: .88rem; z-index: 10; }
.nav a { margin-right: .9rem; text-decoration: none; }
.gap { background: #fff5f5; border-left: 4px solid var(--bad); padding: .8rem 1rem; margin: 1rem 0; border-radius: 0 6px 6px 0; }
.gap strong { color: var(--bad); }
.resolved { background: #ecf7ec; border-left: 4px solid var(--ok); padding: .8rem 1rem; margin: 1rem 0; border-radius: 0 6px 6px 0; }
.resolved strong { color: var(--ok); }
.open-q { background: #fff8d6; border: 1px solid #e5d76b; padding: .8rem 1rem; margin: 1rem 0; border-radius: 6px; font-size: .92rem; }
.open-q strong { color: #7a5e00; }
.ascii-diagram { font-family: "SF Mono", Menlo, Consolas, monospace; font-size: .82rem; line-height: 1.3; white-space: pre; background: var(--code-bg); padding: 1rem; border-radius: 6px; overflow-x: auto; }
.yesno { font-weight: 600; }
.yesno.yes { color: var(--ok); }
.yesno.no { color: var(--bad); }
.yesno.partial { color: var(--warn); }
.src { color: var(--muted); font-size: .85em; }
.api-block { background: var(--card); border: 1px solid var(--rule); border-radius: 8px; padding: 1.1rem 1.25rem; margin: 1.5rem 0; }
.api-block h3 { margin-top: 0; }
.meta-row { display: flex; flex-wrap: wrap; gap: .5rem 2rem; margin: .65rem 0 1rem; font-size: .9rem; color: var(--muted); }
.meta-row span strong { color: var(--fg); }
</style>
</head>
<body>
<nav class="nav">
<a href="#tldr">TL;DR</a>
<a href="#post-merge">Post-merge audit</a>
<a href="#coverage">Current coverage</a>
<a href="#missing">Missing APIs</a>
<a href="#cfnotificationcenter">CFNotificationCenter</a>
<a href="#cfpreferences">CFPreferences</a>
<a href="#cfstringtokenizer">CFStringTokenizer</a>
<a href="#lower-priority">Lower priority</a>
<a href="#build">Build integration</a>
<a href="#testing">Testing</a>
</nav>
<h1>libs-corebase — CoreFoundation gaps for WebKit
<span class="pill warn">Sub-plan</span>
</h1>
<p class="subtitle">
What must be added to <code>gnustep/libs-corebase</code> to reach 100% CoreFoundation coverage for the minimal WebKit v5 build. Parent plan: <a href="gnustep-webkit-v5-porting-plan.html">WebKit v5 Cocoa-native porting plan</a>.
</p>
<!-- ═══════════════════════════════════════ TL;DR -->
<section id="tldr">
<h2>TL;DR</h2>
<div class="tldr">
<h3>Three files away from full CF coverage</h3>
<ul>
<li><code>gnustep/libs-corebase</code> currently exposes <strong>648 CF symbols</strong>, compared to Apple's 1302 in the macOS 14 SDK. That sounds like a large gap — but the vast majority of what WebKit actually calls is already present.</li>
<li>For the <strong>minimal WebKit build</strong> (HTML+CSS+JS, no GPU process, no video, no WebRTC), only <strong>3 CF API families are missing</strong>:
<ul>
<li><strong>CFNotificationCenter</strong> — ~70 call sites in WebKit source</li>
<li><strong>CFPreferences</strong> — ~46 call sites</li>
<li><strong>CFStringTokenizer</strong> — ~27 call sites</li>
</ul>
</li>
<li>All three can be implemented by wrapping existing GNUstep/ICU APIs. Each requires roughly one <code>.h</code> and one <code>.c</code> file. Total new code: approximately <strong>600–850 lines</strong>.</li>
<li>The plan: fork <code>gnustep/libs-corebase</code> to <code>pkgdemon/libs-corebase</code>, add these three files, wire them into the GNUstep-make build, and submit upstream PRs.</li>
<li>Everything else in libs-corebase (CFString, CFRunLoop, CFURL, CFBundle, CFPropertyList, CFData, CFNumber, CFDictionary, CFArray, CFSet, CFSocket, CFStream, CFDate, CFLocale, CFError, CFUUID, …) already works and needs no changes.</li>
</ul>
</div>
</section>
<!-- ═══════════════════════════════════════ POST-MERGE AUDIT -->
<section id="post-merge">
<h2>Post-merge audit — 30 DTW-Thalion PRs merged <span class="pill ok">Done</span></h2>
<p>30 PRs from DTW-Thalion were merged into the pkgdemon/libs-corebase fork. These were exclusively correctness and stability fixes across existing APIs — no new CF subsystems were added. The 3 critical gaps (CFNotificationCenter, CFPreferences, CFStringTokenizer) remain at 0% — they must be implemented from scratch.</p>
<h3>What the 30 PRs fixed</h3>
<table>
<thead>
<tr>
<th>Area</th>
<th>Fix</th>
<th>WebKit Impact</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>CFString</code></td>
<td>Buffer overflow in CFStringGetCString/AppendCString</td>
<td>Direct — DOM text encoding, URL construction</td>
</tr>
<tr>
<td><code>CFRunLoop</code></td>
<td>Observer marked valid on creation; timer fire date correction; crash fix removing source from common modes</td>
<td>Direct — WebKit's event loop</td>
</tr>
<tr>
<td><code>CFAttributedString</code></td>
<td>Multi-run attribute storage, substring, attribute removal/replacement</td>
<td>Direct — text rendering pipeline</td>
</tr>
<tr>
<td><code>CFDate/CFCalendar</code></td>
<td>Month calculation fix, week-of-year, unit difference, ordinality, min/max range swap</td>
<td>Direct — JavaScript Date object</td>
</tr>
<tr>
<td><code>CFTimeZone</code></td>
<td>TZif header validation (prevent OOB reads), GMT offset naming</td>
<td>Stability</td>
</tr>
<tr>
<td><code>CFTree</code></td>
<td>Retain/release context info, prepend child, out-of-range index safety</td>
<td>Stability</td>
</tr>
<tr>
<td><code>CFURL</code></td>
<td>Absolute URL path scan, empty URL safety, percent-escape buffer sizing</td>
<td>Direct — URL handling</td>
</tr>
<tr>
<td><code>CFUUID</code></td>
<td>Complete rewrite of string parsing</td>
<td>Stability</td>
</tr>
<tr>
<td><code>CFPropertyList</code></td>
<td>Deep copy fix (was copying empty destination, not source)</td>
<td>Direct — plist/preferences</td>
</tr>
<tr>
<td><code>CFSocket</code></td>
<td>Register type, correct address accessors</td>
<td>Networking</td>
</tr>
<tr>
<td><code>CFXMLNode</code></td>
<td>Type code, value comparison, entity escaping</td>
<td>XML parsing</td>
</tr>
<tr>
<td><code>CFStream</code></td>
<td>Memory stream status and error reporting</td>
<td>I/O</td>
</tr>
<tr>
<td><code>GSUnicode</code></td>
<td>UTF-8 BOM, UTF-32 byte order, non-lossy ASCII, printf digit parsing</td>
<td>String encoding</td>
</tr>
<tr>
<td><code>CFDictionary/CFSet</code></td>
<td>Fast enumeration fix (was creating new enumerator each call, never terminating)</td>
<td>Direct — all dictionary iteration</td>
</tr>
</tbody>
</table>
<h3>Remaining gaps (unchanged)</h3>
<div class="gap">
The 3 critical APIs needed for the minimal WebKit build are <strong>still completely absent</strong> — no headers, no source, no stubs:
<ol>
<li>CFNotificationCenter (~70 calls in WebKit)</li>
<li>CFPreferences (~46 calls in WebKit)</li>
<li>CFStringTokenizer (~27 calls in WebKit)</li>
</ol>
These must be implemented from scratch as documented in sections 3a–3c below.
</div>
<h3>Updated coverage</h3>
<div class="resolved">
libs-corebase coverage is now <strong>~80%</strong> of the CF type surface (up from ~75% pre-merge due to correctness fixes making existing implementations actually usable). For the minimal WebKit build, the 3 missing APIs are the only remaining blockers.
</div>
</section>
<!-- ═══════════════════════════════════════ CURRENT COVERAGE -->
<section id="coverage">
<h2>Current coverage</h2>
<p>The table below lists CF subsystems that <code>libs-corebase</code> already implements and that WebKit exercises. All are available and functional for the minimal build target. Symbol counts are approximate and based on the libs-corebase source tree as of mid-2026.</p>
<table>
<thead>
<tr>
<th>CF subsystem</th>
<th>Key types / functions</th>
<th>In libs-corebase?</th>
<th>Notes</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>CFString</code></td>
<td>CFStringRef, CFMutableStringRef, CFStringCreateWithCString, CFStringGetCString, CFStringCompare, CFStringFind, CFStringAppend, …</td>
<td><span class="yesno yes">Yes</span></td>
<td>Most-used CF type in WebKit. Well-implemented.</td>
</tr>
<tr>
<td><code>CFArray</code></td>
<td>CFArrayRef, CFMutableArrayRef, CFArrayCreate, CFArrayGetValueAtIndex, CFArrayAppendValue, CFArraySortValues, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFDictionary</code></td>
<td>CFDictionaryRef, CFMutableDictionaryRef, CFDictionaryCreate, CFDictionaryGetValue, CFDictionarySetValue, CFDictionaryApplyFunction, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFSet</code></td>
<td>CFSetRef, CFMutableSetRef, CFSetCreate, CFSetAddValue, CFSetContainsValue, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFData</code></td>
<td>CFDataRef, CFMutableDataRef, CFDataCreate, CFDataGetBytePtr, CFDataGetLength, CFDataAppendBytes, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFNumber</code></td>
<td>CFNumberRef, CFNumberCreate, CFNumberGetValue, CFNumberCompare, kCFNumberIntType, kCFNumberDoubleType, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFRunLoop</code></td>
<td>CFRunLoopRef, CFRunLoopGetMain, CFRunLoopGetCurrent, CFRunLoopRun, CFRunLoopStop, CFRunLoopWakeUp, CFRunLoopAddSource, CFRunLoopAddTimer, …</td>
<td><span class="yesno yes">Yes</span></td>
<td>Critical for WebKit's event processing.</td>
</tr>
<tr>
<td><code>CFRunLoopSource</code></td>
<td>CFRunLoopSourceRef, CFRunLoopSourceCreate, CFRunLoopSourceSignal, CFRunLoopSourceInvalidate, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFRunLoopTimer</code></td>
<td>CFRunLoopTimerRef, CFRunLoopTimerCreate, CFRunLoopTimerInvalidate, CFRunLoopTimerGetNextFireDate, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFURL</code></td>
<td>CFURLRef, CFURLCreateWithString, CFURLCreateWithFileSystemPath, CFURLGetString, CFURLCopyFileSystemPath, CFURLCopyPathExtension, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFBundle</code></td>
<td>CFBundleRef, CFBundleGetMainBundle, CFBundleCopyResourceURL, CFBundleGetIdentifier, CFBundleCopyLocalizedString, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFPropertyList</code></td>
<td>CFPropertyListRef, CFPropertyListCreateWithData, CFPropertyListCreateData, CFPropertyListIsValid, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFDate</code></td>
<td>CFDateRef, CFDateCreate, CFDateGetAbsoluteTime, CFDateCompare, CFAbsoluteTimeGetCurrent, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFCalendar</code></td>
<td>CFCalendarRef, CFCalendarCopyCurrent, CFCalendarAddComponents, CFCalendarGetComponentDifference, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFTimeZone</code></td>
<td>CFTimeZoneRef, CFTimeZoneCopyDefault, CFTimeZoneCreateWithName, CFTimeZoneGetSecondsFromGMT, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFLocale</code></td>
<td>CFLocaleRef, CFLocaleCopyCurrent, CFLocaleCreateWithLocaleIdentifier, CFLocaleGetIdentifier, CFLocaleGetValue, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFError</code></td>
<td>CFErrorRef, CFErrorCreate, CFErrorGetCode, CFErrorGetDomain, CFErrorCopyDescription, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFSocket</code></td>
<td>CFSocketRef, CFSocketCreate, CFSocketCreateWithNative, CFSocketSetAddress, CFSocketConnectToAddress, CFSocketCreateRunLoopSource, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFStream</code></td>
<td>CFReadStreamRef, CFWriteStreamRef, CFReadStreamCreateWithFile, CFWriteStreamCreateWithFile, CFStreamCreatePairWithSocket, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFUUID</code></td>
<td>CFUUIDRef, CFUUIDCreate, CFUUIDCreateString, CFUUIDCreateFromString, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFBag</code></td>
<td>CFBagRef, CFMutableBagRef, CFBagCreate, CFBagGetCount, CFBagAddValue, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFBinaryHeap</code></td>
<td>CFBinaryHeapRef, CFBinaryHeapCreate, CFBinaryHeapAddValue, CFBinaryHeapGetMinimum, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFBitVector</code></td>
<td>CFBitVectorRef, CFMutableBitVectorRef, CFBitVectorCreate, CFBitVectorGetBitAtIndex, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFTree</code></td>
<td>CFTreeRef, CFTreeCreate, CFTreeAppendChild, CFTreeGetParent, CFTreeApplyFunctionToChildren, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFAttributedString</code></td>
<td>CFAttributedStringRef, CFMutableAttributedStringRef, CFAttributedStringCreate, CFAttributedStringGetAttribute, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFCharacterSet</code></td>
<td>CFCharacterSetRef, CFMutableCharacterSetRef, CFCharacterSetGetPredefined, CFCharacterSetIsCharacterMember, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFDateFormatter</code></td>
<td>CFDateFormatterRef, CFDateFormatterCreate, CFDateFormatterCreateStringWithDate, CFDateFormatterCreateDateFromString, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFNumberFormatter</code></td>
<td>CFNumberFormatterRef, CFNumberFormatterCreate, CFNumberFormatterCreateStringWithNumber, CFNumberFormatterCreateNumberFromString, …</td>
<td><span class="yesno yes">Yes</span></td>
<td></td>
</tr>
<tr>
<td><code>CFByteOrder</code></td>
<td>CFByteOrderGetCurrent, CFSwapInt16BigToHost, CFSwapInt32HostToBig, CFConvertFloat32HostToSwapped, …</td>
<td><span class="yesno yes">Yes</span></td>
<td>Inline functions; no compilation unit needed.</td>
</tr>
<tr>
<td><code>CFRuntime</code></td>
<td>CFTypeID, CFGetTypeID, CFRetain, CFRelease, CFEqual, CFHash, CFCopyDescription, CFAllocatorRef, …</td>
<td><span class="yesno yes">Yes</span></td>
<td>Foundation of the entire CF type system.</td>
</tr>
<tr>
<td><code>CFXMLNode / CFXMLParser</code></td>
<td>CFXMLNodeRef, CFXMLParserRef, CFXMLParserCreate, CFXMLParserParse, …</td>
<td><span class="yesno yes">Yes</span></td>
<td>Deprecated on Apple but present in libs-corebase.</td>
</tr>
</tbody>
</table>
<div class="resolved">
<strong>Result:</strong> 31 CF subsystems confirmed present. The three missing subsystems are detailed in the next section. No other CF APIs appear in WebKit's minimal build call graph.
</div>
</section>
<!-- ═══════════════════════════════════════ MISSING APIs -->
<section id="missing">
<h2>Missing APIs — must add</h2>
<p>These three API families are absent from <code>libs-corebase</code> and are called directly by WebKit source. They are not optional — the minimal build will fail to link without them. Each is straightforwardly implementable by wrapping existing OS-level APIs that are already available on GNUstep/NextBSD.</p>
<table class="compact">
<thead>
<tr>
<th>API</th>
<th>WebKit call sites</th>
<th>Implementation wraps</th>
<th>Est. LOC</th>
<th>New files</th>
</tr>
</thead>
<tbody>
<tr>
<td><a href="#cfnotificationcenter"><code>CFNotificationCenter</code></a></td>
<td>~70</td>
<td>NSNotificationCenter (gnustep-base)</td>
<td>200–300</td>
<td>2 (.h + .c)</td>
</tr>
<tr>
<td><a href="#cfpreferences"><code>CFPreferences</code></a></td>
<td>~46</td>
<td>NSUserDefaults (gnustep-base)</td>
<td>150–200</td>
<td>2 (.h + .c)</td>
</tr>
<tr>
<td><a href="#cfstringtokenizer"><code>CFStringTokenizer</code></a></td>
<td>~27</td>
<td>ICU UBreakIterator (libicu)</td>
<td>250–350</td>
<td>2 (.h + .c)</td>
</tr>
</tbody>
</table>
</section>
<!-- ═══════════════════════════════════════ CFNotificationCenter -->
<section id="cfnotificationcenter">
<h2>3a. CFNotificationCenter</h2>
<div class="api-block">
<h3>Overview</h3>
<div class="meta-row">
<span><strong>Header:</strong> <code>CFNotificationCenter.h</code></span>
<span><strong>Source:</strong> <code>CFNotificationCenter.c</code></span>
<span><strong>WebKit call sites:</strong> ~70</span>
<span><strong>Estimated LOC:</strong> 200–300</span>
<span><strong>Depends on:</strong> gnustep-base (NSNotificationCenter, NSDistributedNotificationCenter)</span>
</div>
<h4>WebKit functions called</h4>
<ul>
<li><code>CFNotificationCenterGetLocalCenter()</code> — by far the most common; used in nearly every observer registration</li>
<li><code>CFNotificationCenterAddObserver()</code> — registers a C callback for a named notification</li>
<li><code>CFNotificationCenterRemoveObserver()</code> — deregisters an observer</li>
<li><code>CFNotificationCenterRemoveEveryObserver()</code> — bulk removal</li>
<li><code>CFNotificationCenterPostNotification()</code> — fires a notification with optional userInfo dictionary</li>
<li><code>CFNotificationCenterGetDistributedCenter()</code> — less critical; used for cross-process notifications (not required for the minimal build but trivial to add)</li>
</ul>
<h4>Implementation strategy</h4>
<p>Wrap <code>NSNotificationCenter</code> from gnustep-base. The CF notification center is a thin veneer over the Objective-C notification system. The local center maps 1:1 to <code>[NSNotificationCenter defaultCenter]</code>. The distributed center maps to <code>[NSDistributedNotificationCenter defaultCenter]</code>, which gnustep-base already implements.</p>
<p>The tricky part is adapting the C callback signature. CF observers use the signature:</p>
<pre><code>typedef void (*CFNotificationCallback)(
CFNotificationCenterRef center,
void *observer,
CFNotificationName name,
const void *object,
CFDictionaryRef userInfo
);</code></pre>
<p>Each registered observer must be wrapped in an Objective-C block or NSObject shim that bridges NSNotification to the CF callback. The shim holds the CF callback pointer, the observer pointer, and the suspension behavior. Use a global <code>CFMutableDictionaryRef</code> (keyed by observer+name+center triplet) to track shims for removal.</p>
<h4>Key constants to define</h4>
<pre><code>/* Suspension behavior when app is in background */
typedef CF_ENUM(CFIndex, CFNotificationSuspensionBehavior) {
CFNotificationSuspensionBehaviorDrop = 1,
CFNotificationSuspensionBehaviorCoalesce = 2,
CFNotificationSuspensionBehaviorHold = 3,
CFNotificationSuspensionBehaviorDeliverImmediately = 4
};
/* Options for CFNotificationCenterPostNotification */
typedef CF_OPTIONS(CFOptionFlags, CFNotificationPostOptions) {
kCFNotificationPostToAllSessions = (1 << 0)
};</code></pre>
<h4>Complete function signatures to implement</h4>
<pre><code>/* CFNotificationCenter.h */
CF_EXPORT CFTypeID CFNotificationCenterGetTypeID(void);
CF_EXPORT CFNotificationCenterRef CFNotificationCenterGetLocalCenter(void);
CF_EXPORT CFNotificationCenterRef CFNotificationCenterGetDistributedCenter(void);
CF_EXPORT CFNotificationCenterRef CFNotificationCenterGetDarwinNotifyCenter(void);
CF_EXPORT void CFNotificationCenterAddObserver(
CFNotificationCenterRef center,
const void *observer,
CFNotificationCallback callBack,
CFStringRef name,
const void *object,
CFNotificationSuspensionBehavior suspensionBehavior
);
CF_EXPORT void CFNotificationCenterRemoveObserver(
CFNotificationCenterRef center,
const void *observer,
CFNotificationName name,
const void *object
);
CF_EXPORT void CFNotificationCenterRemoveEveryObserver(
CFNotificationCenterRef center,
const void *observer
);
CF_EXPORT void CFNotificationCenterPostNotification(
CFNotificationCenterRef center,
CFNotificationName name,
const void *object,
CFDictionaryRef userInfo,
Boolean deliverImmediately
);
CF_EXPORT void CFNotificationCenterPostNotificationWithOptions(
CFNotificationCenterRef center,
CFNotificationName name,
const void *object,
CFDictionaryRef userInfo,
CFOptionFlags options
);</code></pre>
<h4>Key implementation sketch (CFNotificationCenter.c)</h4>
<pre><code>#import <Foundation/NSNotificationCenter.h>
#import <Foundation/NSDistributedNotificationCenter.h>
#import <Foundation/NSDictionary.h>
#import <Foundation/NSString.h>
#include "CFNotificationCenter.h"
#include "CFInternal.h"
/* Observer shim: bridges NSNotification -> CF callback */
@interface _CFNotificationObserver : NSObject {
@public
CFNotificationCallback _callback;
void *_observer;
CFNotificationCenterRef _center;
}
- (void)handleNotification:(NSNotification *)note;
@end
static CFNotificationCenterRef __localCenter = NULL;
static CFNotificationCenterRef __distCenter = NULL;
static pthread_mutex_t __centerLock = PTHREAD_MUTEX_INITIALIZER;
/* Global map: (observer ptr, name string) -> _CFNotificationObserver */
static CFMutableDictionaryRef __observerMap = NULL;
CFNotificationCenterRef CFNotificationCenterGetLocalCenter(void)
{
pthread_mutex_lock(&__centerLock);
if (!__localCenter) {
/* Allocate a CF runtime instance wrapping [NSNotificationCenter defaultCenter] */
__localCenter = _CFNotificationCenterCreate(kCFNotificationCenterLocal);
}
pthread_mutex_unlock(&__centerLock);
return __localCenter;
}
CFNotificationCenterRef CFNotificationCenterGetDistributedCenter(void)
{
pthread_mutex_lock(&__centerLock);
if (!__distCenter) {
__distCenter = _CFNotificationCenterCreate(kCFNotificationCenterDistributed);
}
pthread_mutex_unlock(&__centerLock);
return __distCenter;
}
void CFNotificationCenterAddObserver(
CFNotificationCenterRef center,
const void *observer,
CFNotificationCallback callBack,
CFStringRef name,
const void *object,
CFNotificationSuspensionBehavior suspensionBehavior)
{
_CFNotificationObserver *shim = [[_CFNotificationObserver alloc] init];
shim->_callback = callBack;
shim->_observer = (void *)observer;
shim->_center = center;
NSString *nsName = name ? (NSString *)name : nil;
NSNotificationCenter *nc = _CFNotificationCenterGetNSCenter(center);
[nc addObserver:shim
selector:@selector(handleNotification:)
name:nsName
object:nil];
/* Store shim for later removal */
_CFNotificationMapStore(center, observer, name, shim);
}
void CFNotificationCenterPostNotification(
CFNotificationCenterRef center,
CFNotificationName name,
const void *object,
CFDictionaryRef userInfo,
Boolean deliverImmediately)
{
NSNotificationCenter *nc = _CFNotificationCenterGetNSCenter(center);
NSString *nsName = (NSString *)name;
NSDictionary *nsInfo = (NSDictionary *)userInfo;
[nc postNotificationName:nsName object:nil userInfo:nsInfo];
}</code></pre>
<div class="open-q">
<strong>Note on Darwin notify center:</strong> <code>CFNotificationCenterGetDarwinNotifyCenter()</code> uses the private <code>notify_post()</code> / <code>notify_register_dispatch()</code> BSD API (part of Apple's libnotify). On GNUstep/NextBSD, stub this to return NULL or a no-op center — WebKit's Darwin-notify usage is limited to system-level power/sleep notifications that are irrelevant for the minimal build.
</div>
</div>
</section>
<!-- ═══════════════════════════════════════ CFPreferences -->
<section id="cfpreferences">
<h2>3b. CFPreferences</h2>
<div class="api-block">
<h3>Overview</h3>
<div class="meta-row">
<span><strong>Header:</strong> <code>CFPreferences.h</code></span>
<span><strong>Source:</strong> <code>CFPreferences.c</code></span>
<span><strong>WebKit call sites:</strong> ~46</span>
<span><strong>Estimated LOC:</strong> 150–200</span>
<span><strong>Depends on:</strong> gnustep-base (NSUserDefaults)</span>
</div>
<h4>WebKit functions called</h4>
<ul>
<li><code>CFPreferencesCopyAppValue(key, appID)</code> — read a value for the current app (most common)</li>
<li><code>CFPreferencesGetAppBooleanValue(key, appID, keyExistsAndHasValidFormat)</code> — typed boolean read</li>
<li><code>CFPreferencesGetAppIntegerValue(key, appID, keyExistsAndHasValidFormat)</code> — typed integer read</li>
<li><code>CFPreferencesSetAppValue(key, value, appID)</code> — write a value</li>
<li><code>CFPreferencesAppSynchronize(appID)</code> — flush to disk</li>
<li><code>CFPreferencesCopyValue(key, appID, user, host)</code> — multi-domain read (less common)</li>
<li><code>CFPreferencesSetValue(key, value, appID, user, host)</code> — multi-domain write</li>
<li><code>CFPreferencesSynchronize(appID, user, host)</code> — flush multi-domain</li>
<li><code>CFPreferencesCopyKeyList(appID, user, host)</code> — enumerate keys</li>
<li><code>CFPreferencesCopyMultiple(keysToFetch, appID, user, host)</code> — bulk read</li>
</ul>
<h4>Implementation strategy</h4>
<p>Wrap <code>NSUserDefaults</code>. The mapping is direct and complete:</p>
<ul>
<li><code>kCFPreferencesCurrentApplication</code> → <code>[NSUserDefaults standardUserDefaults]</code></li>
<li><code>kCFPreferencesAnyApplication</code> → the <code>NSGlobalDomain</code> (accessed via <code>-persistentDomainForName:NSGlobalDomain</code>)</li>
<li><code>kCFPreferencesCurrentUser</code> / <code>kCFPreferencesAnyUser</code> → irrelevant on non-macOS; map to the standard defaults</li>
<li><code>kCFPreferencesCurrentHost</code> / <code>kCFPreferencesAnyHost</code> → map to the standard defaults (host-level prefs are a macOS-specific concept)</li>
</ul>
<p>The <code>appID</code> parameter in most calls is a bundle identifier string (<code>kCFPreferencesCurrentApplication</code> is a sentinel). When the sentinel is passed, use <code>[NSUserDefaults standardUserDefaults]</code> directly. When a real bundle ID is passed, use <code>[[NSUserDefaults alloc] initWithSuiteName:bundleID]</code>.</p>
<h4>Key constants to define</h4>
<pre><code>/* Sentinel strings — defined as extern CFStringRef, initialized to static values */
CF_EXPORT const CFStringRef kCFPreferencesAnyApplication;
CF_EXPORT const CFStringRef kCFPreferencesCurrentApplication;
CF_EXPORT const CFStringRef kCFPreferencesAnyHost;
CF_EXPORT const CFStringRef kCFPreferencesCurrentHost;
CF_EXPORT const CFStringRef kCFPreferencesAnyUser;
CF_EXPORT const CFStringRef kCFPreferencesCurrentUser;</code></pre>
<h4>Complete function signatures to implement</h4>
<pre><code>/* CFPreferences.h */
/* Per-app read/write (most common in WebKit) */
CF_EXPORT CFTypeRef CFPreferencesCopyAppValue(
CFStringRef key,
CFStringRef applicationID
);
CF_EXPORT Boolean CFPreferencesGetAppBooleanValue(
CFStringRef key,
CFStringRef applicationID,
Boolean *keyExistsAndHasValidFormat /* may be NULL */
);
CF_EXPORT CFIndex CFPreferencesGetAppIntegerValue(
CFStringRef key,
CFStringRef applicationID,
Boolean *keyExistsAndHasValidFormat /* may be NULL */
);
CF_EXPORT void CFPreferencesSetAppValue(
CFStringRef key,
CFTypeRef value, /* pass NULL to remove */
CFStringRef applicationID
);
CF_EXPORT Boolean CFPreferencesAppSynchronize(
CFStringRef applicationID
);
CF_EXPORT Boolean CFPreferencesAppValueIsForced(
CFStringRef key,
CFStringRef applicationID
);
/* Multi-domain read/write */
CF_EXPORT CFTypeRef CFPreferencesCopyValue(
CFStringRef key,
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT void CFPreferencesSetValue(
CFStringRef key,
CFTypeRef value,
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT Boolean CFPreferencesSynchronize(
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT CFArrayRef CFPreferencesCopyApplicationList(
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT CFDictionaryRef CFPreferencesCopyMultiple(
CFArrayRef keysToFetch, /* pass NULL for all keys */
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT void CFPreferencesSetMultiple(
CFDictionaryRef keysToSet,
CFArrayRef keysToRemove,
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);
CF_EXPORT CFArrayRef CFPreferencesCopyKeyList(
CFStringRef applicationID,
CFStringRef userName,
CFStringRef hostName
);</code></pre>
<h4>Key implementation sketch (CFPreferences.c)</h4>
<pre><code>#import <Foundation/NSUserDefaults.h>
#import <Foundation/NSString.h>
#import <Foundation/NSNumber.h>
#include "CFPreferences.h"
#include "CFString.h"
const CFStringRef kCFPreferencesCurrentApplication =
(CFStringRef)@"kCFPreferencesCurrentApplication";
const CFStringRef kCFPreferencesAnyApplication =
(CFStringRef)@"kCFPreferencesAnyApplication";
const CFStringRef kCFPreferencesCurrentUser =
(CFStringRef)@"kCFPreferencesCurrentUser";
const CFStringRef kCFPreferencesAnyUser =
(CFStringRef)@"kCFPreferencesAnyUser";
const CFStringRef kCFPreferencesCurrentHost =
(CFStringRef)@"kCFPreferencesCurrentHost";
const CFStringRef kCFPreferencesAnyHost =
(CFStringRef)@"kCFPreferencesAnyHost";
static NSUserDefaults *_defaultsForAppID(CFStringRef applicationID)
{
if (applicationID == kCFPreferencesCurrentApplication
|| [(NSString *)applicationID isEqualToString:
(NSString *)kCFPreferencesCurrentApplication])
return [NSUserDefaults standardUserDefaults];
/* Named suite — note: NSUserDefaults initWithSuiteName: is available
in gnustep-base and behaves like a per-bundle defaults domain. */
return [[[NSUserDefaults alloc]
initWithSuiteName:(NSString *)applicationID] autorelease];
}
CFTypeRef CFPreferencesCopyAppValue(CFStringRef key, CFStringRef applicationID)
{
NSUserDefaults *ud = _defaultsForAppID(applicationID);
id value = [ud objectForKey:(NSString *)key];
if (!value) return NULL;
CFRetain((CFTypeRef)value);
return (CFTypeRef)value;
}
Boolean CFPreferencesGetAppBooleanValue(
CFStringRef key, CFStringRef applicationID, Boolean *keyExists)
{
NSUserDefaults *ud = _defaultsForAppID(applicationID);
id value = [ud objectForKey:(NSString *)key];
if (!value) {
if (keyExists) *keyExists = false;
return false;
}
if (keyExists) *keyExists = true;
return [ud boolForKey:(NSString *)key];
}
CFIndex CFPreferencesGetAppIntegerValue(
CFStringRef key, CFStringRef applicationID, Boolean *keyExists)
{
NSUserDefaults *ud = _defaultsForAppID(applicationID);
id value = [ud objectForKey:(NSString *)key];
if (!value) {
if (keyExists) *keyExists = false;
return 0;
}
if (keyExists) *keyExists = true;
return (CFIndex)[ud integerForKey:(NSString *)key];
}
void CFPreferencesSetAppValue(
CFStringRef key, CFTypeRef value, CFStringRef applicationID)
{
NSUserDefaults *ud = _defaultsForAppID(applicationID);
if (value)
[ud setObject:(id)value forKey:(NSString *)key];
else
[ud removeObjectForKey:(NSString *)key];
}
Boolean CFPreferencesAppSynchronize(CFStringRef applicationID)
{
NSUserDefaults *ud = _defaultsForAppID(applicationID);
[ud synchronize];
return true;
}</code></pre>
</div>
</section>
<!-- ═══════════════════════════════════════ CFStringTokenizer -->
<section id="cfstringtokenizer">
<h2>3c. CFStringTokenizer</h2>
<div class="api-block">
<h3>Overview</h3>
<div class="meta-row">
<span><strong>Header:</strong> <code>CFStringTokenizer.h</code></span>
<span><strong>Source:</strong> <code>CFStringTokenizer.c</code></span>
<span><strong>WebKit call sites:</strong> ~27</span>
<span><strong>Estimated LOC:</strong> 250–350</span>
<span><strong>Depends on:</strong> ICU (libicu — already a WebKit dependency)</span>
</div>
<h4>WebKit functions called</h4>
<ul>
<li><code>CFStringTokenizerCreate(allocator, string, range, unit, locale)</code> — construct a tokenizer for a string</li>
<li><code>CFStringTokenizerSetString(tokenizer, string, range)</code> — replace the string being tokenized</li>
<li><code>CFStringTokenizerAdvanceToNextToken(tokenizer)</code> — move to the next token; returns token type flags</li>
<li><code>CFStringTokenizerGoToTokenAtIndex(tokenizer, index)</code> — seek to the token at a character index</li>
<li><code>CFStringTokenizerGetCurrentTokenRange(tokenizer)</code> — returns CFRange of the current token</li>
<li><code>CFStringTokenizerCopyCurrentTokenAttribute(tokenizer, attribute)</code> — returns language, script, or stem data for the token</li>
</ul>
<h4>ICU mapping</h4>
<p>ICU's <code>UBreakIterator</code> API, available in <code><unicode/ubrk.h></code>, implements exactly the same concept. The unit constants map as follows:</p>
<table class="compact">
<thead>
<tr><th>CF unit constant</th><th>ICU UBreakIteratorType</th><th>Notes</th></tr>
</thead>
<tbody>
<tr>
<td><code>kCFStringTokenizerUnitWord</code></td>
<td><code>UBRK_WORD</code></td>
<td>Standard word boundaries</td>
</tr>
<tr>
<td><code>kCFStringTokenizerUnitSentence</code></td>
<td><code>UBRK_SENTENCE</code></td>
<td>Sentence boundaries</td>
</tr>
<tr>
<td><code>kCFStringTokenizerUnitParagraph</code></td>
<td><code>UBRK_LINE</code></td>
<td>Closest ICU analog to paragraph; CF paragraphs = line breaks</td>
</tr>
<tr>
<td><code>kCFStringTokenizerUnitLineBreak</code></td>
<td><code>UBRK_LINE</code></td>
<td>ICU line-break opportunities</td>
</tr>
<tr>
<td><code>kCFStringTokenizerUnitWordBoundary</code></td>
<td><code>UBRK_WORD</code></td>
<td>Same as word but returns all tokens including whitespace</td>
</tr>
</tbody>
</table>
<p>ICU uses UTF-16 internally, matching CoreFoundation's native encoding. The string passed to the tokenizer must be extracted as a UTF-16 buffer (<code>CFStringGetCharactersPtr</code> or <code>CFStringGetCharacters</code>) and held for the lifetime of the iterator.</p>
<h4>Key constants and types to define</h4>
<pre><code>typedef CF_OPTIONS(CFOptionFlags, CFStringTokenizerTokenType) {
kCFStringTokenizerTokenNone = 0,
kCFStringTokenizerTokenNormal = 1UL << 0,
kCFStringTokenizerTokenHasSubTokensMask = 1UL << 1,
kCFStringTokenizerTokenHasDerivedSubTokensMask = 1UL << 2,
kCFStringTokenizerTokenHasHasNumbersMask = 1UL << 3,
kCFStringTokenizerTokenHasNonLettersMask = 1UL << 4,
kCFStringTokenizerTokenIsCJWordMask = 1UL << 5
};
/* Unit options for CFStringTokenizerCreate */
typedef CF_OPTIONS(CFOptionFlags, CFStringTokenizerUnit) {
kCFStringTokenizerUnitWord = 0,
kCFStringTokenizerUnitSentence = 1,
kCFStringTokenizerUnitParagraph = 2,
kCFStringTokenizerUnitLineBreak = 3,
kCFStringTokenizerUnitWordBoundary = (1UL << 4) | kCFStringTokenizerUnitWord
};
/* Attribute keys for CFStringTokenizerCopyCurrentTokenAttribute */
CF_EXPORT const CFStringRef kCFStringTokenizerAttributeLatinTranscription;
CF_EXPORT const CFStringRef kCFStringTokenizerAttributeLanguage;</code></pre>
<h4>Complete function signatures to implement</h4>
<pre><code>/* CFStringTokenizer.h */
CF_EXPORT CFTypeID CFStringTokenizerGetTypeID(void);
CF_EXPORT CFStringTokenizerRef CFStringTokenizerCreate(
CFAllocatorRef alloc,
CFStringRef string,
CFRange range,
CFOptionFlags unit,
CFLocaleRef locale
);
CF_EXPORT void CFStringTokenizerSetString(
CFStringTokenizerRef tokenizer,
CFStringRef string,
CFRange range
);
CF_EXPORT CFStringTokenizerTokenType CFStringTokenizerAdvanceToNextToken(
CFStringTokenizerRef tokenizer
);
CF_EXPORT CFStringTokenizerTokenType CFStringTokenizerGoToTokenAtIndex(
CFStringTokenizerRef tokenizer,
CFIndex index
);
CF_EXPORT CFRange CFStringTokenizerGetCurrentTokenRange(
CFStringTokenizerRef tokenizer
);