Summary
I have been developing some personal Util modules for production efficiency and recently got into Scenegraph development. I saw an annoying syntax with the SpatialMath that always required specifying if it is (/Verse.org/SpatialMath:) or (/UnrealEngine.com/Temporary/SpatialMath:). I thought to utilize Alias for that so I can reference vector3 without having to always copy paste the specific SpatialMath library.
In my utils module that handles vector math I have these two alias:
VectorMathModule<public> := module:
luf_vector3<public> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<public> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
I was making various SceneGraph module helper functions. When I started creating the functions and utilized luf_vector3 or xyz_vector3, I was having issues doing the basic of references.
using { VectorMathModule }
SceneGraphModule<public> := module:
ExampleFunc(SimpleVector : xyz_vector3):void=
Print("{SimpleVector}")
I tried doing a redundant fix where I copy paste the two alias as <internal>
alias in the module but that did not work either.
When using <internal>
in both modules, I get the following error: Ambiguous identifier;(VectorMathModule :)xyz_vector3 or (SceneGraphModule:)xyz_vector3
If I use <public>
specifier and only have the alias in VectorMathModule, SceneGraphModule functions tell me that luf_vector3
or xyz_vector3
: Can't access a type alias from a preceding expression.(3502)
.
The directory setup I have is
Utility
vector_math_utility.verse (VectorMathModule stored here)
scene_graph_utility.verse (SceneGraphModule stored here)
Please select what you are reporting on:
Verse
What Type of Bug are you experiencing?
Verse
Steps to Reproduce
Do one of the following setups
Module1<public> := module:
luf_vector3<public> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<public> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
# --------------------------------------- #
using . Module1
Module2<public> := module:
ExampleFunction(VectorParameter : xyz_vector3):void={}
Module1<public> := module:
luf_vector3<internal> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<internal> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
# --------------------------------------- #
using . Module1
Module2<public> := module:
luf_vector3<internal> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<internal> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
ExampleFunction(VectorParameter : xyz_vector3):void={}
Directory Setup
Utils
module1_utils.verse
module2_utils.verse
Expected Result
ExampleFunction()
should be able to easily use xyz_vector3
or luf_vector3
in a different module with ease.
Observed Result
Neither methods seemed to have worked without resulting in error messages.
This results in Can't access a type alias from a preceding expression.(3502)
Module1<public> := module:
luf_vector3<public> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<public> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
# --------------------------------------- #
using . Module1
Module2<public> := module:
ExampleFunction(VectorParameter : xyz_vector3):void={}
This results in Ambiguous identifier;(Module1:)xyz_vector3 or (Module2:)xyz_vector3
Module1<public> := module:
luf_vector3<internal> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<internal> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
# --------------------------------------- #
using . Module1
Module2<public> := module:
luf_vector3<internal> := (/Verse.org/SpatialMath:)vector3
xyz_vector3<internal> := (/UnrealEngine.com/Temporary/SpatialMath:)vector3
ExampleFunction(VectorParameter : xyz_vector3):void={}
Directory Setup
Utils
module1_utils.verse
module2_utils.verse
Platform(s)
windows