commit
b6a8bec5fc
@ -0,0 +1,20 @@ |
|||||||
|
var CodeManager = require('./src/code/codeManager') |
||||||
|
var StorageViewer = require('./src/storage/storageViewer') |
||||||
|
var StorageResolver = require('./src/storage/storageResolver') |
||||||
|
var TraceManager = require('./src/trace/traceManager') |
||||||
|
|
||||||
|
module.exports = { |
||||||
|
global: { |
||||||
|
web3: null |
||||||
|
}, |
||||||
|
code: { |
||||||
|
CodeManager: CodeManager |
||||||
|
}, |
||||||
|
storage: { |
||||||
|
StorageViewer: StorageViewer, |
||||||
|
StorageResolver: StorageResolver |
||||||
|
}, |
||||||
|
trace: { |
||||||
|
TraceManager: TraceManager |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,81 @@ |
|||||||
|
{ |
||||||
|
"name": "remix-core", |
||||||
|
"version": "0.0.2", |
||||||
|
"description": "Ethereum IDE and tools for the web", |
||||||
|
"contributors": [ |
||||||
|
{ |
||||||
|
"name": "Yann Levreau", |
||||||
|
"email": "yann@ethereum.com" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"name": "Liana Husikyan", |
||||||
|
"email": "liana@ethereum.com" |
||||||
|
} |
||||||
|
], |
||||||
|
"main": "./index.js", |
||||||
|
"dependencies": { |
||||||
|
"babel-preset-es2015": "^6.24.0", |
||||||
|
"babel-plugin-transform-object-assign": "^6.22.0", |
||||||
|
"babel-eslint": "^7.1.1", |
||||||
|
"babelify": "^7.3.0", |
||||||
|
"fast-async": "^6.1.2", |
||||||
|
"npm-link-local": "^1.1.0", |
||||||
|
"remix-lib": "^0.0.1", |
||||||
|
"standard": "^7.0.1", |
||||||
|
"tape": "^4.6.0" |
||||||
|
}, |
||||||
|
"scripts": { |
||||||
|
"postinstall": "npm-link-local ../remix-lib", |
||||||
|
"test": "standard && tape ./test/tests.js" |
||||||
|
}, |
||||||
|
"standard": { |
||||||
|
"ignore": [ |
||||||
|
"node_modules/*", |
||||||
|
"build/*", |
||||||
|
"test/resources/*" |
||||||
|
], |
||||||
|
"parser": "babel-eslint" |
||||||
|
}, |
||||||
|
"repository": { |
||||||
|
"type": "git", |
||||||
|
"url": "git+https://github.com/ethereum/remix.git" |
||||||
|
}, |
||||||
|
"author": "cpp-ethereum team", |
||||||
|
"license": "MIT", |
||||||
|
"bugs": { |
||||||
|
"url": "https://github.com/ethereum/remix/issues" |
||||||
|
}, |
||||||
|
"homepage": "https://github.com/ethereum/remix#readme", |
||||||
|
"browserify": { |
||||||
|
"transform": [ |
||||||
|
[ |
||||||
|
"babelify", |
||||||
|
{ |
||||||
|
"plugins": [ |
||||||
|
[ |
||||||
|
"fast-async", |
||||||
|
{ |
||||||
|
"runtimePatten": null, |
||||||
|
"compiler": { |
||||||
|
"promises": true, |
||||||
|
"es7": true, |
||||||
|
"noRuntime": true, |
||||||
|
"wrapAwait": true |
||||||
|
} |
||||||
|
} |
||||||
|
], |
||||||
|
"transform-object-assign" |
||||||
|
] |
||||||
|
} |
||||||
|
], |
||||||
|
[ |
||||||
|
"babelify", |
||||||
|
{ |
||||||
|
"presets": [ |
||||||
|
"es2015" |
||||||
|
] |
||||||
|
} |
||||||
|
] |
||||||
|
] |
||||||
|
} |
||||||
|
} |
@ -1,6 +1,7 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var EventManager = require('../lib/eventManager') |
var remixLib = require('remix-lib') |
||||||
var helper = require('../helpers/traceHelper') |
var EventManager = remixLib.EventManager |
||||||
|
var helper = remixLib.helpers.trace |
||||||
|
|
||||||
/** |
/** |
||||||
* allow to manage breakpoint |
* allow to manage breakpoint |
@ -1,8 +1,9 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var traceHelper = require('../helpers/traceHelper') |
var remixLib = require('remix-lib') |
||||||
|
var EventManager = remixLib.EventManager |
||||||
|
var traceHelper = remixLib.helpers.trace |
||||||
|
var SourceMappingDecoder = remixLib.SourceMappingDecoder |
||||||
var codeResolver = require('./codeResolver') |
var codeResolver = require('./codeResolver') |
||||||
var EventManager = require('../lib/eventManager') |
|
||||||
var SourceMappingDecoder = require('../util/sourceMappingDecoder') |
|
||||||
|
|
||||||
/* |
/* |
||||||
resolve contract code referenced by vmtrace in order to be used by asm listview. |
resolve contract code referenced by vmtrace in order to be used by asm listview. |
@ -1,7 +1,8 @@ |
|||||||
'use strict' |
'use strict' |
||||||
|
|
||||||
var parseCode = require('./codeUtils').parseCode |
var parseCode = require('./codeUtils').parseCode |
||||||
var util = require('../helpers/util') |
var remixLib = require('remix-lib') |
||||||
|
var util = remixLib.util |
||||||
|
|
||||||
var createExpressions = function (instructions) { |
var createExpressions = function (instructions) { |
||||||
var expressions = [] |
var expressions = [] |
@ -1,4 +1,5 @@ |
|||||||
var global = require('../helpers/global') |
var remixLib = require('remix-lib') |
||||||
|
var global = remixLib.global |
||||||
|
|
||||||
module.exports = { |
module.exports = { |
||||||
decodeMappingsKeys: decodeMappingsKeys |
decodeMappingsKeys: decodeMappingsKeys |
@ -1,5 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var traceHelper = require('../helpers/traceHelper') |
var remixLib = require('remix-lib') |
||||||
|
var traceHelper = remixLib.helpers.trace |
||||||
|
|
||||||
function TraceAnalyser (_cache) { |
function TraceAnalyser (_cache) { |
||||||
this.traceCache = _cache |
this.traceCache = _cache |
@ -1,5 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var helper = require('../helpers/util') |
var remixLib = require('remix-lib') |
||||||
|
var helper = remixLib.util |
||||||
|
|
||||||
function TraceCache () { |
function TraceCache () { |
||||||
this.init() |
this.init() |
@ -1,6 +1,7 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var traceHelper = require('../helpers/traceHelper') |
var remixLib = require('remix-lib') |
||||||
var util = require('../helpers/util') |
var traceHelper = remixLib.helpers.trace |
||||||
|
var util = remixLib.util |
||||||
|
|
||||||
function TraceStepManager (_traceAnalyser) { |
function TraceStepManager (_traceAnalyser) { |
||||||
this.traceAnalyser = _traceAnalyser |
this.traceAnalyser = _traceAnalyser |
@ -0,0 +1,3 @@ |
|||||||
|
require('./traceManager.js') |
||||||
|
require('./codeManager.js') |
||||||
|
require('./disassembler.js') |
Before Width: | Height: | Size: 348 KiB After Width: | Height: | Size: 348 KiB |
@ -0,0 +1,26 @@ |
|||||||
|
'use strict' |
||||||
|
var VMDebugger = require('./src/ui/VmDebugger') |
||||||
|
var Debugger = require('./src/ui/Ethdebugger') |
||||||
|
var BasicPanel = require('./src/ui/BasicPanel') |
||||||
|
var TreeView = require('./src/ui/TreeView') |
||||||
|
var styleGuide = require('./src/ui/styles/style-guide') |
||||||
|
|
||||||
|
if (typeof (module) !== 'undefined' && typeof (module.exports) !== 'undefined') { |
||||||
|
module.exports = modules() |
||||||
|
} |
||||||
|
|
||||||
|
if (typeof (window) !== 'undefined') { |
||||||
|
window.remix = modules() |
||||||
|
} |
||||||
|
|
||||||
|
function modules () { |
||||||
|
return { |
||||||
|
ui: { |
||||||
|
Debugger: Debugger, |
||||||
|
VMdebugger: VMDebugger, |
||||||
|
BasicPanel: BasicPanel, |
||||||
|
TreeView: TreeView, |
||||||
|
styleGuide: styleGuide |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -1,7 +1,8 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var style = require('./styles/basicStyles') |
var style = require('./styles/basicStyles') |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
var ui = require('../helpers/ui') |
var remixLib = require('remix-lib') |
||||||
|
var ui = remixLib.helpers.ui |
||||||
|
|
||||||
var csjs = require('csjs-inject') |
var csjs = require('csjs-inject') |
||||||
|
|
@ -1,5 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var EventManager = require('../lib/eventManager') |
var remixLib = require('remix-lib') |
||||||
|
var EventManager = remixLib.EventManager |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
var csjs = require('csjs-inject') |
var csjs = require('csjs-inject') |
@ -1,9 +1,10 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var style = require('./styles/basicStyles') |
var style = require('./styles/basicStyles') |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
var ui = require('../helpers/ui') |
var remixLib = require('remix-lib') |
||||||
|
var ui = remixLib.helpers.ui |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var EventManager = require('../lib/eventManager') |
var EventManager = remixLib.EventManager |
||||||
var csjs = require('csjs-inject') |
var csjs = require('csjs-inject') |
||||||
var styleGuide = require('./styles/style-guide') |
var styleGuide = require('./styles/style-guide') |
||||||
var styles = styleGuide() |
var styles = styleGuide() |
@ -1,9 +1,10 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
var ui = require('../helpers/ui') |
var remixLib = require('remix-lib') |
||||||
|
var ui = remixLib.helpers.ui |
||||||
var styleDropdown = require('./styles/dropdownPanel') |
var styleDropdown = require('./styles/dropdownPanel') |
||||||
var TreeView = require('./TreeView') |
var TreeView = require('./TreeView') |
||||||
var EventManager = require('../lib/eventManager') |
var EventManager = remixLib.EventManager |
||||||
|
|
||||||
var csjs = require('csjs-inject') |
var csjs = require('csjs-inject') |
||||||
var styleGuide = require('./styles/style-guide') |
var styleGuide = require('./styles/style-guide') |
@ -1,6 +1,7 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var StorageViewer = require('../storage/storageViewer') |
var remixCore = require('remix-core') |
||||||
|
var StorageViewer = remixCore.storage.StorageViewer |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
function FullStoragesChanges (_parent, _traceManager) { |
function FullStoragesChanges (_parent, _traceManager) { |
@ -1,8 +1,9 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var style = require('./styles/sliderStyles') |
var style = require('./styles/sliderStyles') |
||||||
var EventManager = require('../lib/eventManager') |
var remixLib = require('remix-lib') |
||||||
|
var EventManager = remixLib.EventManager |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
var ui = require('../helpers/ui') |
var ui = remixLib.helpers.ui |
||||||
|
|
||||||
class Slider { |
class Slider { |
||||||
constructor (_traceManager, _stepOverride) { |
constructor (_traceManager, _stepOverride) { |
@ -1,8 +1,10 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var localDecoder = require('../solidity/localDecoder') |
var remixSolidity = require('remix-solidity') |
||||||
|
var localDecoder = remixSolidity.localDecoder |
||||||
var solidityTypeFormatter = require('./SolidityTypeFormatter') |
var solidityTypeFormatter = require('./SolidityTypeFormatter') |
||||||
var StorageViewer = require('../storage/storageViewer') |
var remixCore = require('remix-core') |
||||||
|
var StorageViewer = remixCore.storage.StorageViewer |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
class SolidityLocals { |
class SolidityLocals { |
@ -1,8 +1,10 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var stateDecoder = require('../solidity/stateDecoder') |
var remixSolidity = require('remix-solidity') |
||||||
|
var stateDecoder = remixSolidity.stateDecoder |
||||||
var solidityTypeFormatter = require('./SolidityTypeFormatter') |
var solidityTypeFormatter = require('./SolidityTypeFormatter') |
||||||
var StorageViewer = require('../storage/storageViewer') |
var remixCore = require('remix-core') |
||||||
|
var StorageViewer = remixCore.storage.StorageViewer |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
function SolidityState (_parent, _traceManager, _codeManager, _solidityProxy) { |
function SolidityState (_parent, _traceManager, _codeManager, _solidityProxy) { |
@ -1,6 +1,7 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var ui = require('../helpers/ui') |
var remixLib = require('remix-lib') |
||||||
|
var ui = remixLib.helpers.ui |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
function StackPanel (_parent, _traceManager) { |
function StackPanel (_parent, _traceManager) { |
@ -1,6 +1,7 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var DropdownPanel = require('./DropdownPanel') |
var DropdownPanel = require('./DropdownPanel') |
||||||
var StorageViewer = require('../storage/storageViewer') |
var remixCore = require('remix-core') |
||||||
|
var StorageViewer = remixCore.storage.StorageViewer |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
|
|
||||||
function StoragePanel (_parent, _traceManager) { |
function StoragePanel (_parent, _traceManager) { |
@ -1,7 +1,8 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var yo = require('yo-yo') |
var yo = require('yo-yo') |
||||||
var style = require('./styles/treeView') |
var style = require('./styles/treeView') |
||||||
var ui = require('../helpers/ui') |
var remixLib = require('remix-lib') |
||||||
|
var ui = remixLib.helpers.ui |
||||||
|
|
||||||
class TreeView { |
class TreeView { |
||||||
|
|
File diff suppressed because one or more lines are too long
@ -0,0 +1,40 @@ |
|||||||
|
'use strict' |
||||||
|
var EventManager = require('./src/eventManager') |
||||||
|
var traceHelper = require('./src/helpers/traceHelper') |
||||||
|
var uiHelper = require('./src/helpers/uiHelper') |
||||||
|
var SourceMappingDecoder = require('./src/sourceMappingDecoder') |
||||||
|
var SourceLocationTracker = require('./src/sourceLocationTracker') |
||||||
|
var init = require('./src/init') |
||||||
|
var util = require('./src/util') |
||||||
|
var Web3Providers = require('./src/web3Provider/web3Providers') |
||||||
|
var DummyProvider = require('./src/web3Provider/dummyProvider') |
||||||
|
var AstWalker = require('./src/astWalker') |
||||||
|
var global = require('./src/global') |
||||||
|
|
||||||
|
if (typeof (module) !== 'undefined' && typeof (module.exports) !== 'undefined') { |
||||||
|
module.exports = modules() |
||||||
|
} |
||||||
|
|
||||||
|
if (typeof (window) !== 'undefined') { |
||||||
|
window.remix = modules() |
||||||
|
} |
||||||
|
|
||||||
|
function modules () { |
||||||
|
return { |
||||||
|
EventManager: EventManager, |
||||||
|
helpers: { |
||||||
|
trace: traceHelper, |
||||||
|
ui: uiHelper |
||||||
|
}, |
||||||
|
vm: { |
||||||
|
Web3Providers: Web3Providers, |
||||||
|
DummyProvider: DummyProvider |
||||||
|
}, |
||||||
|
SourceMappingDecoder: SourceMappingDecoder, |
||||||
|
SourceLocationTracker: SourceLocationTracker, |
||||||
|
init: init, |
||||||
|
util: util, |
||||||
|
AstWalker: AstWalker, |
||||||
|
global: global |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,43 @@ |
|||||||
|
{ |
||||||
|
"name": "remix-lib", |
||||||
|
"version": "0.0.2", |
||||||
|
"description": "Ethereum IDE and tools for the web", |
||||||
|
"contributors": [ |
||||||
|
{ |
||||||
|
"name": "Yann Levreau", |
||||||
|
"email": "yann@ethdev.com" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"name": "Liana Husikyan", |
||||||
|
"email": "liana@ethdev.com" |
||||||
|
} |
||||||
|
], |
||||||
|
"main": "./index.js", |
||||||
|
"dependencies": { |
||||||
|
"ethereumjs-util": "^4.5.0", |
||||||
|
"web3": "^0.15.3", |
||||||
|
"solc": "^0.4.13", |
||||||
|
"standard": "^7.0.1", |
||||||
|
"tape": "^4.6.0" |
||||||
|
}, |
||||||
|
"scripts": { |
||||||
|
"test": "standard && tape ./test/tests.js" |
||||||
|
}, |
||||||
|
"repository": { |
||||||
|
"type": "git", |
||||||
|
"url": "git+https://github.com/ethereum/remix.git" |
||||||
|
}, |
||||||
|
"author": "cpp-ethereum team", |
||||||
|
"license": "MIT", |
||||||
|
"bugs": { |
||||||
|
"url": "https://github.com/ethereum/remix/issues" |
||||||
|
}, |
||||||
|
"homepage": "https://github.com/ethereum/remix#readme", |
||||||
|
"standard": { |
||||||
|
"ignore": [ |
||||||
|
"node_modules/*", |
||||||
|
"build/*", |
||||||
|
"test/resources/*" |
||||||
|
] |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,3 @@ |
|||||||
|
module.exports = { |
||||||
|
web3: null |
||||||
|
} |
@ -1,5 +1,5 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var ui = require('../helpers/ui') |
var ui = require('./uiHelper') |
||||||
module.exports = { |
module.exports = { |
||||||
// vmTraceIndex has to point to a CALL, CODECALL, ...
|
// vmTraceIndex has to point to a CALL, CODECALL, ...
|
||||||
resolveCalledAddress: function (vmTraceIndex, trace) { |
resolveCalledAddress: function (vmTraceIndex, trace) { |
@ -1,5 +1,22 @@ |
|||||||
'use strict' |
'use strict' |
||||||
|
var Web3 = require('web3') |
||||||
|
|
||||||
module.exports = { |
module.exports = { |
||||||
|
loadWeb3: function () { |
||||||
|
var web3 = new Web3() |
||||||
|
web3.setProvider(new web3.providers.HttpProvider('http://localhost:8545')) |
||||||
|
this.extend(web3) |
||||||
|
return web3 |
||||||
|
}, |
||||||
|
|
||||||
|
extendWeb3: function (web3) { |
||||||
|
this.extend(web3) |
||||||
|
}, |
||||||
|
|
||||||
|
setProvider: function (web3, url) { |
||||||
|
web3.setProvider(new web3.providers.HttpProvider(url)) |
||||||
|
}, |
||||||
|
|
||||||
extend: function (web3) { |
extend: function (web3) { |
||||||
if (!web3._extend) { |
if (!web3._extend) { |
||||||
return |
return |
@ -1,8 +1,8 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var EventManager = require('../lib/eventManager') |
var EventManager = require('./eventManager') |
||||||
var helper = require('../helpers/traceHelper') |
var helper = require('./helpers/traceHelper') |
||||||
var SourceMappingDecoder = require('../util/sourceMappingDecoder') |
var SourceMappingDecoder = require('./sourceMappingDecoder') |
||||||
var util = require('../helpers/util') |
var util = require('./util') |
||||||
|
|
||||||
/** |
/** |
||||||
* Process the source code location for the current executing bytecode |
* Process the source code location for the current executing bytecode |
@ -1,5 +1,5 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var util = require('../helpers/util') |
var util = require('./util') |
||||||
var AstWalker = require('./astWalker') |
var AstWalker = require('./astWalker') |
||||||
|
|
||||||
/** |
/** |
@ -1,6 +1,15 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var ethutil = require('ethereumjs-util') |
var ethutil = require('ethereumjs-util') |
||||||
|
|
||||||
|
/* |
||||||
|
contains misc util: @TODO should be splitted |
||||||
|
- hex convertion |
||||||
|
- binary search |
||||||
|
- CALL related look up |
||||||
|
- sha3 calculation |
||||||
|
- swarm hash extraction |
||||||
|
- bytecode comparison |
||||||
|
*/ |
||||||
module.exports = { |
module.exports = { |
||||||
/* |
/* |
||||||
ints: IntArray |
ints: IntArray |
@ -1,5 +1,5 @@ |
|||||||
var Web3VMProvider = require('./web3VmProvider') |
var Web3VMProvider = require('./web3VmProvider') |
||||||
var init = require('../helpers/init') |
var init = require('../init') |
||||||
|
|
||||||
function Web3Providers () { |
function Web3Providers () { |
||||||
this.modes = {} |
this.modes = {} |
@ -1,5 +1,5 @@ |
|||||||
var util = require('../helpers/util') |
var util = require('../util') |
||||||
var uiutil = require('../helpers/ui') |
var uiutil = require('../helpers/uiHelper') |
||||||
var traceHelper = require('../helpers/traceHelper') |
var traceHelper = require('../helpers/traceHelper') |
||||||
var ethutil = require('ethereumjs-util') |
var ethutil = require('ethereumjs-util') |
||||||
var Web3 = require('web3') |
var Web3 = require('web3') |
@ -1,6 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var tape = require('tape') |
var tape = require('tape') |
||||||
var AstWalker = require('../src/util/astWalker') |
var AstWalker = require('../src/astWalker') |
||||||
var node = require('./resources/ast') |
var node = require('./resources/ast') |
||||||
|
|
||||||
tape('ASTWalker', function (t) { |
tape('ASTWalker', function (t) { |
@ -1,6 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var tape = require('tape') |
var tape = require('tape') |
||||||
var EventManager = require('../src/lib/eventManager') |
var EventManager = require('../src/eventManager') |
||||||
tape('eventManager', function (t) { |
tape('eventManager', function (t) { |
||||||
t.test('eventManager', function (st) { |
t.test('eventManager', function (st) { |
||||||
var events = new EventManager() |
var events = new EventManager() |
@ -0,0 +1,4 @@ |
|||||||
|
require('./astwalker.js') |
||||||
|
require('./eventManager.js') |
||||||
|
require('./sourceMappingDecoder.js') |
||||||
|
require('./util.js') |
@ -0,0 +1,31 @@ |
|||||||
|
'use strict' |
||||||
|
var tape = require('tape') |
||||||
|
var util = require('../src/util') |
||||||
|
|
||||||
|
tape('Util', function (t) { |
||||||
|
t.test('lowerbound', function (st) { |
||||||
|
st.plan(7) |
||||||
|
var array = [2, 5, 8, 9, 45, 56, 78] |
||||||
|
var lowerBound = util.findLowerBound(10, array) |
||||||
|
st.equal(lowerBound, 3) |
||||||
|
|
||||||
|
lowerBound = util.findLowerBound(3, array) |
||||||
|
st.equal(lowerBound, 0) |
||||||
|
|
||||||
|
lowerBound = util.findLowerBound(100, array) |
||||||
|
st.equal(lowerBound, 6) |
||||||
|
|
||||||
|
lowerBound = util.findLowerBound(1, array) |
||||||
|
st.equal(lowerBound, -1) |
||||||
|
|
||||||
|
lowerBound = util.findLowerBound(45, array) |
||||||
|
st.equal(lowerBound, 4) |
||||||
|
|
||||||
|
array = [2, 5, 8, 9, 9, 45, 56, 78] |
||||||
|
lowerBound = util.findLowerBound(9, array) |
||||||
|
st.equal(lowerBound, 4) |
||||||
|
|
||||||
|
lowerBound = util.findLowerBound(9, []) |
||||||
|
st.equal(lowerBound, -1) |
||||||
|
}) |
||||||
|
}) |
@ -0,0 +1,11 @@ |
|||||||
|
var InternalCallTree = require('./src/internalCallTree') |
||||||
|
var SolidityProxy = require('./src/solidityProxy') |
||||||
|
var localDecoder = require('./src/localDecoder') |
||||||
|
var stateDecoder = require('./src/stateDecoder') |
||||||
|
|
||||||
|
module.exports = { |
||||||
|
InternalCallTree: InternalCallTree, |
||||||
|
SolidityProxy: SolidityProxy, |
||||||
|
localDecoder: localDecoder, |
||||||
|
stateDecoder: stateDecoder |
||||||
|
} |
@ -0,0 +1,84 @@ |
|||||||
|
{ |
||||||
|
"name": "remix-solidity", |
||||||
|
"version": "0.0.2", |
||||||
|
"description": "Ethereum IDE and tools for the web", |
||||||
|
"contributors": [ |
||||||
|
{ |
||||||
|
"name": "Yann Levreau", |
||||||
|
"email": "yann@ethdev.com" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"name": "Liana Husikyan", |
||||||
|
"email": "liana@ethdev.com" |
||||||
|
} |
||||||
|
], |
||||||
|
"main": "./index.js", |
||||||
|
"dependencies": { |
||||||
|
"babel-preset-es2015": "^6.24.0", |
||||||
|
"babel-plugin-transform-object-assign": "^6.22.0", |
||||||
|
"babel-eslint": "^7.1.1", |
||||||
|
"babelify": "^7.3.0", |
||||||
|
"ethereumjs-util": "^4.5.0", |
||||||
|
"ethereumjs-vm": "2.3.1", |
||||||
|
"fast-async": "^6.1.2", |
||||||
|
"npm-link-local": "^1.1.0", |
||||||
|
"remix-core": "^0.0.1", |
||||||
|
"remix-lib": "^0.0.1", |
||||||
|
"solc": "^0.4.13", |
||||||
|
"standard": "^7.0.1", |
||||||
|
"tape": "^4.6.0" |
||||||
|
}, |
||||||
|
"scripts": { |
||||||
|
"postinstall": "npm-link-local ../remix-lib && npm-link-local ../remix-core", |
||||||
|
"test": "standard && tape ./test/tests.js" |
||||||
|
}, |
||||||
|
"standard": { |
||||||
|
"ignore": [ |
||||||
|
"node_modules/*", |
||||||
|
"build/*" |
||||||
|
], |
||||||
|
"parser": "babel-eslint" |
||||||
|
}, |
||||||
|
"repository": { |
||||||
|
"type": "git", |
||||||
|
"url": "git+https://github.com/ethereum/remix.git" |
||||||
|
}, |
||||||
|
"author": "cpp-ethereum team", |
||||||
|
"license": "MIT", |
||||||
|
"bugs": { |
||||||
|
"url": "https://github.com/ethereum/remix/issues" |
||||||
|
}, |
||||||
|
"homepage": "https://github.com/ethereum/remix#readme", |
||||||
|
"browserify": { |
||||||
|
"transform": [ |
||||||
|
[ |
||||||
|
"babelify", |
||||||
|
{ |
||||||
|
"plugins": [ |
||||||
|
[ |
||||||
|
"fast-async", |
||||||
|
{ |
||||||
|
"runtimePatten": null, |
||||||
|
"compiler": { |
||||||
|
"promises": true, |
||||||
|
"es7": true, |
||||||
|
"noRuntime": true, |
||||||
|
"wrapAwait": true |
||||||
|
} |
||||||
|
} |
||||||
|
], |
||||||
|
"transform-object-assign" |
||||||
|
] |
||||||
|
} |
||||||
|
], |
||||||
|
[ |
||||||
|
"babelify", |
||||||
|
{ |
||||||
|
"presets": [ |
||||||
|
"es2015" |
||||||
|
] |
||||||
|
} |
||||||
|
] |
||||||
|
] |
||||||
|
} |
||||||
|
} |
@ -1,5 +1,6 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var AstWalker = require('../util/astWalker') |
var remixLib = require('remix-lib') |
||||||
|
var AstWalker = remixLib.AstWalker |
||||||
|
|
||||||
/** |
/** |
||||||
* return all contract definitions of the given @astList |
* return all contract definitions of the given @astList |
@ -1,10 +1,11 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var SourceLocationTracker = require('../code/sourceLocationTracker') |
var remixLib = require('remix-lib') |
||||||
var AstWalker = require('./astWalker') |
var SourceLocationTracker = remixLib.SourceLocationTracker |
||||||
var EventManager = require('../lib/eventManager') |
var AstWalker = remixLib.AstWalker |
||||||
var decodeInfo = require('../solidity/decodeInfo') |
var EventManager = remixLib.EventManager |
||||||
var util = require('../helpers/util') |
var decodeInfo = require('./decodeInfo') |
||||||
var traceHelper = require('../helpers/traceHelper') |
var util = remixLib.util |
||||||
|
var traceHelper = remixLib.helpers.trace |
||||||
|
|
||||||
/** |
/** |
||||||
* Tree representing internal jump into function. |
* Tree representing internal jump into function. |
@ -1,8 +1,9 @@ |
|||||||
'use strict' |
'use strict' |
||||||
var traceHelper = require('../helpers/traceHelper') |
var remixLib = require('remix-lib') |
||||||
|
var traceHelper = remixLib.helpers.trace |
||||||
var stateDecoder = require('./stateDecoder') |
var stateDecoder = require('./stateDecoder') |
||||||
var astHelper = require('./astHelper') |
var astHelper = require('./astHelper') |
||||||
var util = require('../helpers/util') |
var util = remixLib.util |
||||||
|
|
||||||
class SolidityProxy { |
class SolidityProxy { |
||||||
constructor (traceManager, codeManager) { |
constructor (traceManager, codeManager) { |
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue