forked from chapel-lang/chapel
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Jade Abraham <[email protected]>
- Loading branch information
1 parent
8844bed
commit 29cd3cc
Showing
5 changed files
with
81 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
module MissingInIntent { | ||
|
||
record myData { | ||
var x: int; | ||
proc init() { | ||
x = 0; | ||
} | ||
proc init(in d: int) { | ||
x = d; | ||
} | ||
} | ||
|
||
|
||
record R { | ||
var x: int; | ||
var y: myData; | ||
proc init(newX: int) { | ||
x = newX; | ||
y = new myData(); | ||
} | ||
proc init(newY: myData) { | ||
x = 0; | ||
y = newY; | ||
} | ||
@chplcheck.ignore("UnusedFormal") | ||
proc init(newY: myData, dummy: int) { | ||
x = newY.x; | ||
y = new myData(); | ||
} | ||
@chplcheck.ignore("UnusedFormal") | ||
proc init(newY: myData, dummy: int, dummy2: int) { | ||
init this; | ||
x = 0; | ||
y = newY; | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
MissingInIntent.chpl:17: node violates rule MissingInIntent | ||
MissingInIntent.chpl:21: node violates rule MissingInIntent | ||
[Success matching fixit for MissingInIntent] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
module MissingInIntent { | ||
|
||
record myData { | ||
var x: int; | ||
proc init() { | ||
x = 0; | ||
} | ||
proc init(in d: int) { | ||
x = d; | ||
} | ||
} | ||
|
||
|
||
record R { | ||
var x: int; | ||
var y: myData; | ||
proc init(in newX: int) { | ||
x = newX; | ||
y = new myData(); | ||
} | ||
proc init(in newY: myData) { | ||
x = 0; | ||
y = newY; | ||
} | ||
@chplcheck.ignore("UnusedFormal") | ||
proc init(newY: myData, dummy: int) { | ||
x = newY.x; | ||
y = new myData(); | ||
} | ||
@chplcheck.ignore("UnusedFormal") | ||
proc init(newY: myData, dummy: int, dummy2: int) { | ||
init this; | ||
x = 0; | ||
y = newY; | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters