Knowledge Base Article

Example Code Error in Nios II Processor Reference Handbook, Application Binary Interface Chapter

Description

In the Application Binary Interface chapter of the Nios II Processor Reference Handbook, Example 7-3 (“Returned struct is Larger than 8 Bytes”) contains a typographical error. *value should be replaced by &value.

Resolution

The correct code example is as follows:

void b(STRUCT *p_result, int i, int j)

{

...

*p_result = result;

}

void a(...)

{

STRUCT value;

...

b(&value, i, j);

}

Updated 6 days ago
Version 3.0
No CommentsBe the first to comment