Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(38)

Unified Diff: include/v8.h

Issue 14850016: Don't use anonymous types declared in an anonymous union. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
diff --git a/include/v8.h b/include/v8.h
index 0cb9df7896ade609b06553738e5b981f378521b3..c3ef3c0a4dece87f411cf38f026a8460e6e7a17b 100644
--- a/include/v8.h
+++ b/include/v8.h
@@ -3841,25 +3841,29 @@ struct JitCodeEvent {
// CODE_ADD_LINE_POS_INFO and CODE_END_LINE_INFO_RECORDING events.
void* user_data;
+ struct name_t {
+ // Name of the object associated with the code, note that the string is not
+ // zero-terminated.
+ const char* str;
+ // Number of chars in str.
+ size_t len;
+ };
+
+ struct line_info_t {
+ // PC offset
+ size_t offset;
+ // Code postion
+ size_t pos;
+ // The position type.
+ PositionType position_type;
+ };
+
union {
// Only valid for CODE_ADDED.
- struct {
- // Name of the object associated with the code, note that the string is
- // not zero-terminated.
- const char* str;
- // Number of chars in str.
- size_t len;
- } name;
+ struct name_t name;
// Only valid for CODE_ADD_LINE_POS_INFO
- struct {
- // PC offset
- size_t offset;
- // Code postion
- size_t pos;
- // The position type.
- PositionType position_type;
- } line_info;
+ struct line_info_t line_info;
// New location of instructions. Only valid for CODE_MOVED.
void* new_code_start;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698