MCPcopy Create free account
hub / github.com/coreboot/coreboot / print_fastmap

Function print_fastmap

util/kconfig/regex.c:487–513  ·  view source on GitHub ↗
(fastmap)

Source from the content-addressed store, hash-verified

485/* Print the fastmap in human-readable form. */
486
487void
488print_fastmap (fastmap)
489 char *fastmap;
490{
491 unsigned was_a_range = 0;
492 unsigned i = 0;
493
494 while (i < (1 << BYTEWIDTH))
495 {
496 if (fastmap[i++])
497 {
498 was_a_range = 0;
499 printchar (i - 1);
500 while (i < (1 << BYTEWIDTH) && fastmap[i])
501 {
502 was_a_range = 1;
503 i++;
504 }
505 if (was_a_range)
506 {
507 printf ("-");
508 printchar (i - 1);
509 }
510 }
511 }
512 putchar ('\n');
513}
514
515
516/* Print a compiled pattern string in human-readable form, starting at

Callers 1

print_compiled_patternFunction · 0.85

Calls 2

printfFunction · 0.85
putcharFunction · 0.85

Tested by

no test coverage detected