Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
inox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LARA
inox
Commits
a0698e3e
Commit
a0698e3e
authored
10 years ago
by
Manos Koukoutos
Committed by
Etienne Kneuss
10 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Remove MutableTyped. Really this time.
parent
f1d7ec44
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/scala/leon/purescala/Common.scala
+0
-6
0 additions, 6 deletions
src/main/scala/leon/purescala/Common.scala
src/main/scala/leon/purescala/TypeTrees.scala
+0
-19
0 additions, 19 deletions
src/main/scala/leon/purescala/TypeTrees.scala
with
0 additions
and
25 deletions
src/main/scala/leon/purescala/Common.scala
+
0
−
6
View file @
a0698e3e
...
...
@@ -13,12 +13,6 @@ object Common {
abstract
class
Tree
extends
Positioned
with
Serializable
{
def
copiedFrom
(
o
:
Tree
)
:
this.
type
=
{
setPos
(
o
)
(
this
,
o
)
match
{
// do not force if already set
case
(
t1
:
MutableTyped
,
t2
:
Typed
)
if
!
t1
.
isTyped
=>
t1
.
setType
(
t2
.
getType
)
case
_
=>
}
this
}
...
...
This diff is collapsed.
Click to expand it.
src/main/scala/leon/purescala/TypeTrees.scala
+
0
−
19
View file @
a0698e3e
...
...
@@ -11,30 +11,11 @@ object TypeTrees {
import
Definitions._
import
TypeTreeOps._
/**
* HasType indicates that structure is typed
*
* setType not necessarily defined though
*/
trait
Typed
{
def
getType
:
TypeTree
def
isTyped
:
Boolean
=
(
getType
!=
Untyped
)
}
trait
MutableTyped
extends
Typed
{
self
=>
private
var
_type
:
Option
[
TypeTree
]
=
None
def
getType
:
TypeTree
=
_type
getOrElse
Untyped
def
setType
(
tt
:
TypeTree
)
:
self.
type
=
_type
match
{
case
None
=>
_type
=
Some
(
tt
);
this
case
Some
(
o
)
if
o
!=
tt
=>
scala
.
sys
.
error
(
"Resetting type information! Type ["
+
o
+
"] is modified to ["
+
tt
)
case
_
=>
this
}
}
class
TypeErrorException
(
msg
:
String
)
extends
Exception
(
msg
)
object
TypeErrorException
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment