MCPcopy Create free account
hub / github.com/SoarGroup/Soar / find_chunk

Function find_chunk

Core/SoarKernel/src/explain.cpp:277–294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

275 **************************************************************************/
276
277explain_chunk_str* find_chunk(agent* thisAgent, explain_chunk_str* chunk, char* name)
278{
279
280 while (chunk != NULL)
281 {
282 if (strcmp(chunk->name, name) == 0)
283 {
284 return (chunk);
285 }
286 chunk = chunk->next_chunk;
287 }
288
289 print(thisAgent, "Could not find the chunk. Maybe explain was not on when it was created.");
290 /* BUGBUG: this doesn't belong here! changed for bug 608 */
291 print(thisAgent, "\nTo turn on explain: save-backtraces --enable before the chunk is created.\n");
292
293 return (NULL);
294}
295
296
297/***************************************************************************

Callers 4

ExplainChunksFunction · 0.85
explain_chunkFunction · 0.85
explain_cond_listFunction · 0.85

Calls 1

printFunction · 0.85

Tested by

no test coverage detected