mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-22 17:55:50 +00:00
Bug 1383436 - Part 10: Use MToIntegerInt32 when inlining charAt and charCodeAt. r=jandem
This matches the spec better and relaxes the input argument constraints for both functions. Differential Revision: https://phabricator.services.mozilla.com/D37293 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
0540825b30
commit
9549d17872
@ -2153,7 +2153,7 @@ IonBuilder::InliningResult IonBuilder::inlineStrCharCodeAt(CallInfo& callInfo) {
|
||||
|
||||
callInfo.setImplicitlyUsedUnchecked();
|
||||
|
||||
MInstruction* index = MToNumberInt32::New(alloc(), callInfo.getArg(0));
|
||||
MInstruction* index = MToIntegerInt32::New(alloc(), callInfo.getArg(0));
|
||||
current->add(index);
|
||||
|
||||
MStringLength* length = MStringLength::New(alloc(), callInfo.thisArg());
|
||||
@ -2282,7 +2282,7 @@ IonBuilder::InliningResult IonBuilder::inlineStrCharAt(CallInfo& callInfo) {
|
||||
|
||||
callInfo.setImplicitlyUsedUnchecked();
|
||||
|
||||
MInstruction* index = MToNumberInt32::New(alloc(), callInfo.getArg(0));
|
||||
MInstruction* index = MToIntegerInt32::New(alloc(), callInfo.getArg(0));
|
||||
current->add(index);
|
||||
|
||||
MStringLength* length = MStringLength::New(alloc(), callInfo.thisArg());
|
||||
|
Loading…
Reference in New Issue
Block a user