Closed Bug 749864 Opened 13 years ago Closed 13 years ago

Typed array argument codegen for bindings

Categories

(Core :: DOM: Core & HTML, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla15

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(1 file, 1 obsolete file)

Once bug 742145 is fixed...
Blocks: 749866
I think this depends on the infrastructure bug 748267. Also, I didn't do typed array return values yet, because I have no real way to test them.
Attachment #619254 - Flags: review?(peterv)
Depends on: 748267
Summary: Typed array codegen for bindings → Typed array argument codegen for bindings
Whiteboard: [needs review]
Whiteboard: [needs review] → [need review]
Comment on attachment 619254 [details] [diff] [review] Codegen for typed array and arraybuffer arguments. Review of attachment 619254 [details] [diff] [review]: ----------------------------------------------------------------- ::: content/base/src/nsXMLHttpRequest.cpp @@ +2633,5 @@ > aContentType.SetIsVoid(true); > aCharset.Truncate(); > > + PRInt32 length = aArrayBuffer->mLength; > + char* data = reinterpret_cast<char*>(aArrayBuffer->mData); Can this be a static_cast?
No. Can't static_cast from uint8_t* to char*. At least not on my compiler. ;)
Depends on: 747827
Attachment #626287 - Flags: review?(peterv)
Attachment #619254 - Attachment is obsolete: true
Attachment #619254 - Flags: review?(peterv)
Comment on attachment 626287 [details] [diff] [review] Updated to be a little simpler Review of attachment 626287 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/bindings/Codegen.py @@ +1414,5 @@ > + elif type.isArrayBufferView(): > + name = "ArrayBufferView" > + jsname = "TypedArrayObject" > + else: > + name = type.name Can't you always set name to type.name, even for ArrayBuffer and ArrayBufferView?
Attachment #626287 - Flags: review?(peterv) → review+
> Can't you always set name to type.name, even for ArrayBuffer and ArrayBufferView? I think so, yes. Will do.
Status: NEW → RESOLVED
Closed: 13 years ago
Flags: in-testsuite?
Resolution: --- → FIXED
Whiteboard: [need review]
Target Milestone: --- → mozilla15
Flags: in-testsuite? → in-testsuite+
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: