-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Get rid of quantifiers in pointer cast proof helpers, improve naming
- Loading branch information
1 parent
bede2fc
commit df9ebc4
Showing
6 changed files
with
231 additions
and
154 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
13 changes: 13 additions & 0 deletions
13
src/col/vct/col/ast/expr/heap/read/DerefPointerTypedImpl.scala
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,13 @@ | ||
package vct.col.ast.expr.heap.read | ||
|
||
import vct.col.ast.ops.DerefPointerTypedOps | ||
import vct.col.ast.{DerefPointerTyped, Type} | ||
import vct.col.print._ | ||
|
||
trait DerefPointerTypedImpl[G] extends DerefPointerTypedOps[G] { | ||
this: DerefPointerTyped[G] => | ||
override def t: Type[G] = elementType | ||
|
||
override def precedence: Int = Precedence.PREFIX | ||
override def layout(implicit ctx: Ctx): Doc = Text("*") <> assoc(pointer) | ||
} |
11 changes: 11 additions & 0 deletions
11
src/col/vct/col/ast/family/location/TypedPointerLocationImpl.scala
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,11 @@ | ||
package vct.col.ast.family.location | ||
|
||
import vct.col.ast.TypedPointerLocation | ||
import vct.col.ast.ops.TypedPointerLocationOps | ||
import vct.col.print.{Ctx, Doc, Text} | ||
|
||
trait TypedPointerLocationImpl[G] extends TypedPointerLocationOps[G] { | ||
this: TypedPointerLocation[G] => | ||
override def layout(implicit ctx: Ctx): Doc = | ||
Text("(") <> pointerType <> ")" <> pointer | ||
} |
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
Oops, something went wrong.