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

Side by Side Diff: Source/bindings/v8/V8BindingMacros.h

Issue 57483002: Implement File constructor. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Addressed most feedback. Created 7 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « Source/bindings/bindings.gypi ('k') | Source/bindings/v8/custom/V8BlobCustom.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 24 matching lines...) Expand all
35 35
36 #define V8TRYCATCH(type, var, value) \ 36 #define V8TRYCATCH(type, var, value) \
37 type var; \ 37 type var; \
38 { \ 38 { \
39 v8::TryCatch block; \ 39 v8::TryCatch block; \
40 var = (value); \ 40 var = (value); \
41 if (block.HasCaught()) \ 41 if (block.HasCaught()) \
42 return block.ReThrow(); \ 42 return block.ReThrow(); \
43 } 43 }
44 44
45 #define V8TRYCATCH_RETURN(type, var, value, retVal) \
46 type var; \
47 { \
48 v8::TryCatch block; \
49 var = (value); \
50 if (block.HasCaught()) { \
51 block.ReThrow(); \
52 return retVal; \
53 } \
54 }
55
45 #define V8TRYCATCH_VOID(type, var, value) \ 56 #define V8TRYCATCH_VOID(type, var, value) \
46 type var; \ 57 type var; \
47 { \ 58 { \
48 v8::TryCatch block; \ 59 v8::TryCatch block; \
49 var = (value); \ 60 var = (value); \
50 if (block.HasCaught()) { \ 61 if (block.HasCaught()) { \
51 block.ReThrow(); \ 62 block.ReThrow(); \
52 return; \ 63 return; \
53 } \ 64 } \
54 } 65 }
(...skipping 22 matching lines...) Expand all
77 return retVal; 88 return retVal;
78 89
79 #define V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(type, var, value) \ 90 #define V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(type, var, value) \
80 type var(value); \ 91 type var(value); \
81 if (!var.prepare()) \ 92 if (!var.prepare()) \
82 return; 93 return;
83 94
84 } // namespace WebCore 95 } // namespace WebCore
85 96
86 #endif // V8BindingMacros_h 97 #endif // V8BindingMacros_h
OLDNEW
« no previous file with comments | « Source/bindings/bindings.gypi ('k') | Source/bindings/v8/custom/V8BlobCustom.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698