Removed debuggin symbols and indirect symbol pointers. Added calloc and strchr to builtins
This commit is contained in:
parent
f935be10c9
commit
06e6bf31f4
|
@ -1,7 +1,7 @@
|
||||||
function sort(V, N, tmp, i, j) {
|
function sort(V, N, tmp, i, j) {
|
||||||
V[-1] = ""; # Used as a sentinel before V[0].
|
V[-1] = ""; # Used as a sentinel before V[0].
|
||||||
for (i = 1; i < N; i++)
|
for (i = 1; i < N; i++)
|
||||||
for (j = i; V[j - 1] > V[j]; j--) {
|
for (j = i; V[j - 1] > V[j]; j--) {
|
||||||
tmp = V[j];
|
tmp = V[j];
|
||||||
V[j] = V[j - 1];
|
V[j] = V[j - 1];
|
||||||
V[j - 1] = tmp;
|
V[j - 1] = tmp;
|
||||||
|
@ -14,14 +14,16 @@ BEGIN {
|
||||||
builtin["printf"] = "int printf(const char *, ...)";
|
builtin["printf"] = "int printf(const char *, ...)";
|
||||||
builtin["sprintf"] = "int sprintf(char *, const char *, ...)";
|
builtin["sprintf"] = "int sprintf(char *, const char *, ...)";
|
||||||
builtin["malloc"] = "void *malloc()";
|
builtin["malloc"] = "void *malloc()";
|
||||||
|
builtin["calloc"] = "void *calloc()";
|
||||||
builtin["memcpy"] = "void *memcpy()";
|
builtin["memcpy"] = "void *memcpy()";
|
||||||
builtin["memset"] = "void *memset()";
|
builtin["memset"] = "void *memset()";
|
||||||
builtin["memmove"] = "void *memmove()";
|
builtin["memmove"] = "void *memmove()";
|
||||||
builtin["strcpy"] = "char *strcpy()";
|
builtin["strcpy"] = "char *strcpy()";
|
||||||
|
builtin["strchr"] = "char *strchr()";
|
||||||
builtin[""] = "";
|
builtin[""] = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
/^[0123456789abcdef]+ [ABCDGINRSTUVW] / {
|
/^[0123456789abcdef]+ [ABCDGRSTUVW] / {
|
||||||
if ($3 != "symbols" && $3 != "symbols_nelts") {
|
if ($3 != "symbols" && $3 != "symbols_nelts") {
|
||||||
name[nname] = $3;
|
name[nname] = $3;
|
||||||
nname++;
|
nname++;
|
||||||
|
|
Loading…
Reference in a new issue