Skip to content
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

Extract mutable builder from ModuleScope #9914

Merged
merged 27 commits into from
Jun 5, 2024
Merged
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
4da192d
Minor refactorings
hubertp Apr 30, 2024
f2122ec
wip
hubertp May 2, 2024
bfdf093
don't reset types in scopes
hubertp May 9, 2024
2484337
Make builders usage explicit
hubertp May 9, 2024
c49ae59
minor allocation optimizations
hubertp May 10, 2024
e6ec56d
reduce lock scope
hubertp May 10, 2024
201d76e
remove redundant DelayedModuleScope
hubertp May 10, 2024
c7da06b
nits
hubertp May 10, 2024
696d44f
Merge branch 'develop' into wip/hubert/9736-visualizations
hubertp May 24, 2024
a53bf6c
Illustrate when immutable ModulesScope is created
hubertp May 24, 2024
08c13ee
Introduce ImportExportScope proxy
hubertp May 28, 2024
d88d27d
Ditch `get_unresolved_symbol_scope`
hubertp May 28, 2024
1f347d0
Drop built/build check for ModuleScope.Builder
hubertp Jun 2, 2024
1f61c3f
ModuleScope.reset() no more
hubertp Jun 3, 2024
02117cf
cleanup
hubertp Jun 3, 2024
10c48be
drop aux methods by delegating to proxy
hubertp Jun 3, 2024
209c4a3
Ensure elements of ModuleScope are immutable
hubertp Jun 4, 2024
6cd3c36
Merge branch 'develop' into wip/hubert/9736-visualizations
hubertp Jun 4, 2024
d5f811c
Adapt tests
hubertp Jun 4, 2024
ffbeb95
nit
hubertp Jun 4, 2024
be6330f
PR review
hubertp Jun 4, 2024
aa1286e
Type can only have a reference to Module
hubertp Jun 5, 2024
6b4a208
Drop caching of views
hubertp Jun 5, 2024
7cf8099
PR comments
hubertp Jun 5, 2024
790c0d8
Merge branch 'develop' into wip/hubert/9736-visualizations
hubertp Jun 5, 2024
93d5d69
fix compilation issue
hubertp Jun 5, 2024
ed875eb
nit
hubertp Jun 5, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Adapt tests
hubertp committed Jun 4, 2024
commit d5f811c818e11335d612fe08365cce06e4603c06
Original file line number Diff line number Diff line change
@@ -69,7 +69,8 @@ class ModuleManagementTest
|""".stripMargin)

mainModule.reparse()
val mainFun2 = mainModule.getMethod(assocCons, "main").get
val assocCons2 = mainModule.getAssociatedType
val mainFun2 = mainModule.getMethod(assocCons2, "main").get
mainFun2.execute().asLong() shouldEqual 4567L
}

@@ -88,21 +89,24 @@ class ModuleManagementTest
mainModule.setSource("""
|main = 456
|""".stripMargin)
val mainFun2 = mainModule.getMethod(assocCons, "main").get
val assocCons2 = mainModule.getAssociatedType
val mainFun2 = mainModule.getMethod(assocCons2, "main").get
mainFun2.execute().asLong() shouldEqual 456L

mainModule.setSource("""
|main = 789
|""".stripMargin)
val mainFun3 = mainModule.getMethod(assocCons, "main").get
val assocCons3 = mainModule.getAssociatedType
val mainFun3 = mainModule.getMethod(assocCons3, "main").get
mainFun3.execute().asLong() shouldEqual 789L

ctx.writeMain("""
|main = 987
|""".stripMargin)

mainModule.setSourceFile(ctx.pkg.mainFile.getAbsolutePath)
val mainFun4 = mainModule.getMethod(assocCons, "main").get
val assocCons4 = mainModule.getAssociatedType
val mainFun4 = mainModule.getMethod(assocCons4, "main").get
mainFun4.execute().asLong() shouldEqual 987L
}