-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(gsoc'24): updates and bug fixes from the main simulator #314
fix(gsoc'24): updates and bug fixes from the main simulator #314
Conversation
✅ Deploy Preview for circuitverse ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
simulationArea.simulationQueue.add(this.parent) | ||
} | ||
// For input nodes, resolve its parents if they are resolvable at this point. | ||
if (this.type == NODE_INPUT) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
switch (node.type) { | ||
// TODO: For an output node, a downstream value (value given by elements other than the parent) | ||
// should be overwritten in contention check and should not cause contention. | ||
case NODE_OUTPUT: |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
) | ||
} | ||
// Fallthrough. NODE_OUTPUT propagates like a contention checked NODE_INPUT | ||
case NODE_INPUT: |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
break; | ||
} | ||
// Fallthrough. NODE_INPUT propagates like a bitwidth checked NODE_INTERMEDIATE | ||
case NODE_INTERMEDIATE: |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -162,7 +163,7 @@ | |||
this.id = `node${uniqueIdCounter}` | |||
uniqueIdCounter++ | |||
this.parent = parent | |||
if (type != 2 && this.parent.nodeList !== undefined) { | |||
if (type != NODE_INTERMEDIATE && this.parent.nodeList !== undefined) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -201,7 +202,7 @@ | |||
// This fn is called during rotations and setup | |||
this.refresh() | |||
|
|||
if (this.type == 2) { | |||
if (this.type == NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -226,7 +227,7 @@ | |||
* function to convert a node to intermediate node | |||
*/ | |||
converToIntermediate() { | |||
this.type = 2 | |||
this.type = NODE_INTERMEDIATE |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
*/ | ||
saveObject() { | ||
if (this.type == 2) { | ||
if (this.type == NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -312,7 +313,7 @@ | |||
*/ | |||
updateScope(scope) { | |||
this.scope = scope | |||
if (this.type == 2) this.parent = scope.root | |||
if (this.type == NODE_INTERMEDIATE) this.parent = scope.root |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -670,7 +686,7 @@ | |||
if (!this.wasClicked && this.clicked) { | |||
this.wasClicked = true | |||
this.prev = 'a' | |||
if (this.type == 2) { | |||
if (this.type == NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -712,7 +728,7 @@ | |||
simulationArea.multipleObjectSelections[i].drag() | |||
} | |||
} | |||
if (this.type == 2) { | |||
if (this.type == NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -881,7 +897,7 @@ | |||
simulationArea.lastSelected = n2 | |||
} | |||
|
|||
if (this.type == 2 && simulationArea.mouseDown == false) { | |||
if (this.type == NODE_INTERMEDIATE && simulationArea.mouseDown == false) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -947,7 +963,7 @@ | |||
y == this.parent.scope.allNodes[i].absY() | |||
) { | |||
n = this.parent.scope.allNodes[i] | |||
if (this.type == 2) { | |||
if (this.type == NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
@@ -964,7 +980,7 @@ | |||
for (var i = 0; i < this.parent.scope.wires.length; i++) { | |||
if (this.parent.scope.wires[i].checkConvergence(this)) { | |||
var n = this | |||
if (this.type != 2) { | |||
if (this.type != NODE_INTERMEDIATE) { |
Check failure
Code scanning / ESLint
disallow the use of undeclared variables unless mentioned in `/*global */` comments Error
…into vue-simulator-bug-fixes
@niladrix719 I think this will undo some of the optimizations made by @JoshVarga . Why was this PR delayed ? you mentioned that all the updates from the legacy simulator are already copied, right ? |
@tachyons , I guess there was some miscommunication on my end. The PR was there way back but wasn't merged before |
@niladrix719 Could you create separate PRs to copy changes. PR can't be reviewed in this form. Also give highest priority for this. |
Updates and Bug fixes from the main Simulator