-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lift module information out of result and expose values on module emb…
…edding
- Loading branch information
1 parent
fe78117
commit 6acc197
Showing
3 changed files
with
24 additions
and
11 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
17 changes: 16 additions & 1 deletion
17
chasm/src/commonMain/kotlin/io/github/charlietap/chasm/embedding/shapes/Module.kt
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 |
---|---|---|
@@ -1,5 +1,20 @@ | ||
package io.github.charlietap.chasm.embedding.shapes | ||
|
||
import io.github.charlietap.chasm.embedding.moduleInfo | ||
import io.github.charlietap.chasm.ast.module.Module as InternalModule | ||
|
||
class Module internal constructor(internal val module: InternalModule) | ||
class Module internal constructor( | ||
internal val module: InternalModule, | ||
) { | ||
private val info by lazy { | ||
moduleInfo(this) | ||
} | ||
|
||
val imports by lazy { | ||
info.imports | ||
} | ||
|
||
val exports by lazy { | ||
info.exports | ||
} | ||
} |
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