Skip to content

Commit

Permalink
trace: Format strings must begin/end with double quotes
Browse files Browse the repository at this point in the history
Document the restriction that format strings must begin and end with
double quotes.  This is for easy parsing since we don't run cpp over
trace-events.

Signed-off-by: Stefan Hajnoczi <[email protected]>
Signed-off-by: Blue Swirl <[email protected]>
  • Loading branch information
Stefan Hajnoczi authored and blueswirl committed Oct 20, 2010
1 parent d8023f3 commit cf85cf8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/tracing.txt
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,10 @@ Trace events should use types as follows:

Format strings should reflect the types defined in the trace event. Take
special care to use PRId64 and PRIu64 for int64_t and uint64_t types,
respectively. This ensures portability between 32- and 64-bit platforms.
respectively. This ensures portability between 32- and 64-bit platforms. Note
that format strings must begin and end with double quotes. When using
portability macros, ensure they are preceded and followed by double quotes:
"value %"PRIx64"".

=== Hints for adding new trace events ===

Expand Down

0 comments on commit cf85cf8

Please sign in to comment.