Lines Matching defs:answer

122 static int parse_answer (cpp_reader *, struct answer **, int);
123 static cpp_hashnode *parse_assertion (cpp_reader *, struct answer **, int);
124 static struct answer ** find_answer (cpp_hashnode *, const struct answer *);
1808 /* Read the tokens of the answer into the macro pool, in a directive
1811 ANSWERP to point to the answer. */
1813 parse_answer (cpp_reader *pfile, struct answer **answerp, int type)
1816 struct answer *answer;
1826 /* In a conditional no answer is a test for any answer. It
1834 /* #unassert with no answer is valid - it removes all answers. */
1853 cpp_error (pfile, CPP_DL_ERROR, "missing ')' to complete answer");
1857 /* struct answer includes the space for one token. */
1858 room_needed = (sizeof (struct answer) + acount * sizeof (cpp_token));
1861 _cpp_extend_buff (pfile, &pfile->a_buff, sizeof (struct answer));
1863 dest = &((struct answer *) BUFF_FRONT (pfile->a_buff))->first[acount];
1866 /* Drop whitespace at start, for answer equivalence purposes. */
1873 cpp_error (pfile, CPP_DL_ERROR, "predicate's answer is empty");
1877 answer = (struct answer *) BUFF_FRONT (pfile->a_buff);
1878 answer->count = acount;
1879 answer->next = NULL;
1880 *answerp = answer;
1886 the hash node of the predicate, or 0 on error. If an answer was
1889 parse_assertion (cpp_reader *pfile, struct answer **answerp, int type)
1918 /* Returns a pointer to the pointer to CANDIDATE in the answer chain,
1919 or a pointer to NULL if the answer is not in the chain. */
1920 static struct answer **
1921 find_answer (cpp_hashnode *node, const struct answer *candidate)
1924 struct answer **result;
1928 struct answer *answer = *result;
1930 if (answer->count == candidate->count)
1932 for (i = 0; i < answer->count; i++)
1933 if (! _cpp_equiv_tokens (&answer->first[i], &candidate->first[i]))
1936 if (i == answer->count)
1950 struct answer *answer;
1953 node = parse_assertion (pfile, &answer, T_IF);
1961 (answer == 0 || *find_answer (node, answer) != 0));
1965 /* We don't commit the memory for the answer - it's temporary only. */
1973 struct answer *new_answer;
1981 /* Place the new answer in the answer list. First check there
1995 answer_size = sizeof (struct answer) + ((new_answer->count - 1)
2000 struct answer *temp_answer = new_answer;
2001 new_answer = (struct answer *) pfile->hash_table->alloc_subobject
2019 struct answer *answer;
2021 node = parse_assertion (pfile, &answer, T_UNASSERT);
2025 if (answer)
2027 struct answer **p = find_answer (node, answer), *temp;
2029 /* Remove the answer from the list. */
2034 /* Did we free the last answer? */
2044 /* We don't commit the memory for the answer - it's temporary only. */