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
1b8c97d0
Unverified
Commit
1b8c97d0
authored
Aug 22, 2018
by
yann300
Committed by
GitHub
Aug 22, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #918 from ethereum/remix_debug_fix
remix-debug small fixes
parents
76286bcb
205eec3d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
8 deletions
+9
-8
Ethdebugger.js
remix-debug/src/Ethdebugger.js
+3
-4
breakpointManager.js
remix-lib/src/code/breakpointManager.js
+5
-4
compiler.js
remix-solidity/src/compiler/compiler.js
+1
-0
No files found.
remix-debug/src/Ethdebugger.js
View file @
1b8c97d0
...
...
@@ -36,7 +36,8 @@ function Ethdebugger (opts) {
this
.
opts
=
opts
||
{}
if
(
!
this
.
opts
.
compilationResult
)
this
.
opts
.
compilationResult
=
()
=>
{
return
null
}
this
.
web3
=
opts
.
web3
this
.
executionContext
=
opts
.
executionContext
||
executionContext
this
.
web3
=
opts
.
web3
||
this
.
executionContext
.
web3
this
.
event
=
new
EventManager
()
...
...
@@ -181,7 +182,7 @@ Ethdebugger.prototype.switchProvider = function (type) {
self
.
web3
=
obj
self
.
setManagers
()
// self.traceManager.web3 = self.web3
executionContext
.
detectNetwork
((
error
,
network
)
=>
{
self
.
executionContext
.
detectNetwork
((
error
,
network
)
=>
{
if
(
error
||
!
network
)
{
self
.
web3Debug
=
obj
self
.
web3
=
obj
...
...
@@ -209,7 +210,6 @@ Ethdebugger.prototype.debug = function (tx) {
Ethdebugger
.
prototype
.
unLoad
=
function
()
{
this
.
traceManager
.
init
()
this
.
codeManager
.
clear
()
this
.
stepManager
.
reset
()
this
.
event
.
trigger
(
'traceUnloaded'
)
}
...
...
@@ -225,7 +225,6 @@ Ethdebugger.prototype.debug = function (tx) {
this
.
tx
=
tx
var
self
=
this
this
.
traceManager
.
resolveTrace
(
tx
,
function
(
error
,
result
)
{
console
.
log
(
'trace loaded '
+
result
)
if
(
result
)
{
self
.
event
.
trigger
(
'newTraceLoaded'
,
[
self
.
traceManager
.
trace
])
if
(
self
.
breakpointManager
&&
self
.
breakpointManager
.
hasBreakpoint
())
{
...
...
remix-lib/src/code/breakpointManager.js
View file @
1b8c97d0
...
...
@@ -15,12 +15,13 @@ class BreakpointManager {
* @param {Object} _debugger - type of EthDebugger
* @return {Function} _locationToRowConverter - function implemented by editor which return a column/line position for a char source location
*/
constructor
(
_debugger
,
_locationToRowConverter
)
{
constructor
(
_debugger
,
_locationToRowConverter
,
_jumpToCallback
)
{
this
.
event
=
new
EventManager
()
this
.
debugger
=
_debugger
this
.
breakpoints
=
{}
this
.
locationToRowConverter
=
_locationToRowConverter
this
.
previousLine
this
.
jumpToCallback
=
_jumpToCallback
||
(()
=>
{})
}
/**
...
...
@@ -67,7 +68,7 @@ class BreakpointManager {
sourceLocation
.
start
+
sourceLocation
.
length
>=
previousSourceLocation
.
start
+
previousSourceLocation
.
length
))
{
return
false
}
else
{
if
(
self
.
debugger
.
stepManager
)
self
.
debugger
.
stepManager
.
jumpTo
(
currentStep
)
self
.
jumpToCallback
(
currentStep
)
self
.
event
.
trigger
(
'breakpointHit'
,
[
sourceLocation
,
currentStep
])
return
true
}
...
...
@@ -108,9 +109,9 @@ class BreakpointManager {
this
.
event
.
trigger
(
'NoBreakpointHit'
,
[])
if
(
this
.
debugger
.
stepManager
&&
defaultToLimit
)
{
if
(
direction
===
-
1
)
{
this
.
debugger
.
stepManager
.
jumpTo
(
0
)
this
.
jumpToCallback
(
0
)
}
else
if
(
direction
===
1
)
{
this
.
debugger
.
stepManager
.
jumpTo
(
this
.
debugger
.
traceManager
.
trace
.
length
-
1
)
this
.
jumpToCallback
(
this
.
debugger
.
traceManager
.
trace
.
length
-
1
)
}
}
}
...
...
remix-solidity/src/compiler/compiler.js
View file @
1b8c97d0
...
...
@@ -210,6 +210,7 @@ function Compiler (handleImportCall) {
self
.
event
.
trigger
(
'compilationFinished'
,
[
false
,
data
,
source
])
}
else
if
(
missingInputs
!==
undefined
&&
missingInputs
.
length
>
0
)
{
// try compiling again with the new set of inputs
internalCompile
(
source
.
sources
,
source
.
target
,
missingInputs
)
}
else
{
data
=
updateInterface
(
data
)
...
...
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