Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
ce169246
Commit
ce169246
authored
May 22, 2017
by
yann300
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use helper
parent
3ff34f1f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
Mapping.js
src/solidity/types/Mapping.js
+2
-2
util.js
src/solidity/types/util.js
+2
-1
No files found.
src/solidity/types/Mapping.js
View file @
ce169246
...
...
@@ -19,8 +19,8 @@ class Mapping extends RefType {
type
:
this
.
type
}
}
var
mapSlot
=
util
.
toBN
(
location
.
slot
).
toString
(
16
)
mapSlot
=
ethutil
.
setLengthLeft
(
'0x'
+
mapSlot
,
32
).
toString
(
'hex'
)
var
mapSlot
=
util
.
normalizeHex
(
ethutil
.
bufferToHex
(
location
.
slot
)
)
console
.
log
(
mapSlot
,
mappingsPreimages
)
var
mappingPreimages
=
mappingsPreimages
[
mapSlot
]
var
ret
=
{}
for
(
var
i
in
mappingPreimages
)
{
...
...
src/solidity/types/util.js
View file @
ce169246
...
...
@@ -10,7 +10,8 @@ module.exports = {
toBN
:
toBN
,
add
:
add
,
extractLocation
:
extractLocation
,
removeLocation
:
removeLocation
removeLocation
:
removeLocation
,
normalizeHex
:
normalizeHex
}
function
decodeIntFromHex
(
value
,
byteLength
,
signed
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment